Skip to content

Commit 56f1716

Browse files
Fix/udpate template (#33)
* update * fix: add template for update event * update email * fix --------- Co-authored-by: Sanyam Jain <sanyamjainsj04@gmail.com>
1 parent 25220a2 commit 56f1716

File tree

2 files changed

+202
-20
lines changed

2 files changed

+202
-20
lines changed

app/schemas/email.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ def check_body_for_id(cls, body: dict, values: ValidationInfo) -> dict:
5050
3: {"query", "response"},
5151
4: {"email", "magicLink"},
5252
5: {"name", "eventName", "badgeNumber", "ticketLink"},
53-
6: {"eventName", "updatesText", "updatesLink"},
53+
6: {"eventName", "html", "updatesLink"},
5454
7: {"inviteeName", "eventName", "inviteText", "inviteLink"},
5555
8: {"url","email"},
5656
}

templates/rsvp/update.html

Lines changed: 201 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,39 @@
44
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type" />
55
<meta name="x-apple-disable-message-reformatting" />
66
</head>
7-
<body style="background: #141415; padding-top: 2.5rem; padding-bottom: 2.5rem; font-family: 'Inter', Verdana;">
8-
<table align="center" width="100%" border="0" cellpadding="0" cellspacing="0" role="presentation" style="max-width: 37.5em; margin: 0 auto; padding-left: 1.5rem; padding-right: 1.5rem;">
7+
<body
8+
style="
9+
background: #141415;
10+
padding-top: 2.5rem;
11+
padding-bottom: 2.5rem;
12+
font-family: 'Inter', Verdana;
13+
"
14+
>
15+
<table
16+
align="center"
17+
width="100%"
18+
border="0"
19+
cellpadding="0"
20+
cellspacing="0"
21+
role="presentation"
22+
style="
23+
max-width: 37.5em;
24+
margin: 0 auto;
25+
padding-left: 1.5rem;
26+
padding-right: 1.5rem;
27+
"
28+
>
929
<tbody>
1030
<tr>
1131
<td>
12-
<table align="center" width="100%" border="0" cellpadding="0" cellspacing="0" role="presentation">
32+
<table
33+
align="center"
34+
width="100%"
35+
border="0"
36+
cellpadding="0"
37+
cellspacing="0"
38+
role="presentation"
39+
>
1340
<tbody>
1441
<tr>
1542
<td>
@@ -18,51 +45,206 @@
1845
src="https://raw.githubusercontent.com/TeamShiksha/email-service/refs/heads/main/images/logo.png"
1946
width="100"
2047
height="50"
21-
style="display: block; outline: none; border: none; text-decoration: none;"
48+
style="
49+
display: block;
50+
outline: none;
51+
border: none;
52+
text-decoration: none;
53+
"
2254
/>
2355
</td>
2456
</tr>
2557
</tbody>
2658
</table>
27-
<table align="center" width="100%" border="0" cellpadding="0" cellspacing="0" role="presentation">
59+
<table
60+
align="center"
61+
width="100%"
62+
border="0"
63+
cellpadding="0"
64+
cellspacing="0"
65+
role="presentation"
66+
>
2867
<tbody>
2968
<tr>
3069
<td>
3170
<img
3271
src="https://raw.githubusercontent.com/TeamShiksha/email-service/refs/heads/main/images/verification-img.png"
33-
style="display: block; outline: none; border: none; text-decoration: none; height: auto; width: 100%;"
72+
style="
73+
display: block;
74+
outline: none;
75+
border: none;
76+
text-decoration: none;
77+
height: auto;
78+
width: 100%;
79+
"
3480
/>
35-
<p style="font-size: 1.125rem; line-height: 1.75rem; margin: 16px 0; margin-top: 1.5rem; color: rgb(255, 255, 255);">
36-
We would like to share an important update regarding the communication of the event:
37-
{{eventName}},
81+
<p
82+
style="
83+
font-size: 1.125rem;
84+
line-height: 1.75rem;
85+
margin: 16px 0;
86+
margin-top: 1.5rem;
87+
color: rgb(255, 255, 255);
88+
"
89+
>
90+
We would like to share an important update regarding the
91+
communication of the event: {{ eventName }},
3892
</p>
39-
<p style="background-color: black; color: white; padding: 16px;">{{updatesText}}.</p>
40-
<table align="center" width="100%" border="0" cellpadding="0" cellspacing="0" role="presentation" style="background-color: #ac6aff; width: 100%; font-size: 16px; padding: 10px 20px; text-align: center; margin-left: 0; border-radius: 20px;">
93+
<table
94+
align="center"
95+
width="100%"
96+
border="0"
97+
cellpadding="0"
98+
cellspacing="0"
99+
role="presentation"
100+
style="
101+
background-color: #ac6aff;
102+
width: 100%;
103+
font-size: 16px;
104+
padding: 10px 20px;
105+
text-align: center;
106+
margin-left: 0;
107+
border-radius: 20px;
108+
"
109+
>
110+
{{ html | safe }}
111+
</table>
112+
<table
113+
align="center"
114+
width="100%"
115+
border="0"
116+
cellpadding="0"
117+
cellspacing="0"
118+
role="presentation"
119+
style="
120+
background-color: black;
121+
color: white;
122+
padding: 16px;
123+
"
124+
>
125+
<tbody>
126+
<tr>
127+
<td>
128+
<a
129+
href="{{ updateLink }}"
130+
target="_blank"
131+
style="
132+
color: white;
133+
text-decoration: none;
134+
font-size: 14px;
135+
"
136+
>Check Updates</a
137+
>
138+
</td>
139+
</tr>
140+
</tbody>
141+
</table>
142+
<table
143+
align="center"
144+
width="100%"
145+
border="0"
146+
cellpadding="0"
147+
cellspacing="0"
148+
role="presentation"
149+
style="
150+
background-color: #ac6aff;
151+
width: 100%;
152+
font-size: 16px;
153+
padding: 10px 20px;
154+
text-align: center;
155+
margin-left: 0;
156+
border-radius: 20px;
157+
"
158+
>
41159
<tbody>
42160
<tr>
43161
<td>
44-
<a href="{{updatesLink}}" target="_blank" style="color: white; text-decoration: none; font-size: 14px;">Check Updates</a>
162+
<a
163+
href="{{ updateLink }}"
164+
target="_blank"
165+
style="
166+
color: white;
167+
text-decoration: none;
168+
font-size: 14px;
169+
"
170+
>Check Updates</a
171+
>
45172
</td>
46173
</tr>
47174
</tbody>
48175
</table>
49-
<p style="font-size: 1.125rem; line-height: 1.75rem; margin: 16px 0; margin-top: 1.5rem; color: rgb(255, 255, 255);">
176+
<p
177+
style="
178+
font-size: 1.125rem;
179+
line-height: 1.75rem;
180+
margin: 16px 0;
181+
margin-top: 1.5rem;
182+
color: rgb(255, 255, 255);
183+
"
184+
>
50185
We appreciate your understanding and cooperation with this
51186
adjustment. Should you have any questions or require any
52187
information.
53188
</p>
54-
<p style="font-size: 1.125rem; line-height: 1.75rem; margin: 16px 0; margin-top: 1.5rem; color: rgb(255, 255, 255);">Happy Unforgettable events!</p>
55-
<p style="font-size: 1.125rem; line-height: 1.75rem; margin: 16px 0; margin-top: 1.5rem; color: rgb(255, 255, 255);">RSVP.KIM</p>
189+
<p
190+
style="
191+
font-size: 1.125rem;
192+
line-height: 1.75rem;
193+
margin: 16px 0;
194+
margin-top: 1.5rem;
195+
color: rgb(255, 255, 255);
196+
"
197+
>
198+
Happy Unforgettable events!
199+
</p>
200+
<p
201+
style="
202+
font-size: 1.125rem;
203+
line-height: 1.75rem;
204+
margin: 16px 0;
205+
margin-top: 1.5rem;
206+
color: rgb(255, 255, 255);
207+
"
208+
>
209+
RSVP.KIM
210+
</p>
56211
</td>
57212
</tr>
58213
</tbody>
59214
</table>
60-
<table align="center" width="100%" border="0" cellpadding="0" cellspacing="0" role="presentation">
215+
<table
216+
align="center"
217+
width="100%"
218+
border="0"
219+
cellpadding="0"
220+
cellspacing="0"
221+
role="presentation"
222+
>
61223
<tbody>
62224
<tr>
63225
<td>
64-
<p style="font-size: 0.875rem; line-height: 1.25rem; margin: 16px 0; color: rgb(255, 255, 255);">
65-
© 2025 <a href="https://rsvp.kim" target="_blank" style="color: #ac6aff; text-decoration: none;">RSVP.KIM</a>. All rights reserved.<br /> Powered by <a href="https://team.shiksha/" target="_blank" style="color: #ac6aff; text-decoration: none;">Team Shiksha</a>.
226+
<p
227+
style="
228+
font-size: 0.875rem;
229+
line-height: 1.25rem;
230+
margin: 16px 0;
231+
color: rgb(255, 255, 255);
232+
"
233+
>
234+
© 2025
235+
<a
236+
href="https://rsvp.kim"
237+
target="_blank"
238+
style="color: #ac6aff; text-decoration: none"
239+
>RSVP.KIM</a
240+
>. All rights reserved.<br />
241+
Powered by
242+
<a
243+
href="https://team.shiksha/"
244+
target="_blank"
245+
style="color: #ac6aff; text-decoration: none"
246+
>Team Shiksha</a
247+
>.
66248
</p>
67249
</td>
68250
</tr>
@@ -73,4 +255,4 @@
73255
</tbody>
74256
</table>
75257
</body>
76-
</html>
258+
</html>

0 commit comments

Comments
 (0)