Skip to content

Commit

Permalink
Merge branch 'release/1.10.0' into prod
Browse files Browse the repository at this point in the history
  • Loading branch information
estellecomment committed Jan 29, 2021
2 parents bbe4d01 + 689665c commit a8cf5b6
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 11 deletions.
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ app.set("views", path.join(__dirname, "views"))
app.locals.format = format

app.use("/static", express.static("static"))
// Hack for importing css from npm package
app.use("/~", express.static(path.join(__dirname, "node_modules")))
app.use("/gouvfr", express.static(path.join(__dirname, "node_modules/@gouvfr/all/dist")))
app.use("/chart.js", express.static(path.join(__dirname, "node_modules/chart.js/dist")))
app.use(bodyParser.urlencoded({ extended: false }))

app.use(cookieParser(config.secret))
Expand Down
19 changes: 14 additions & 5 deletions lib/emailer.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ module.exports.sendConfCreatedEmail = async function(
) {
let pollHtml = ""
if (pollUrl) {
pollHtml = `<hr />
pollHtml = `
<div class="paragraph">
<div>
Vous avez une remarque ou une suggestion ?
Expand All @@ -100,7 +100,12 @@ module.exports.sendConfCreatedEmail = async function(
<div>Bonjour,</div>
<div class="paragraph">
<div>Votre conférence téléphonique ${conferenceDay ? `du ${format.formatFrenchDate(new Date(conferenceDay))} ` : "" }est réservée. Elle pourra accueillir jusqu'à 50 personnes.</div>
<div>
Votre conférence téléphonique
<a href="${config.HOSTNAME_WITH_PROTOCOL}">${config.APP_NAME}</a>
${conferenceDay ? `du ${format.formatFrenchDate(new Date(conferenceDay))} ` : "" }
est réservée. Elle pourra accueillir jusqu'à 50 personnes.
</div>
<div>Pour vous y connecter : <div>
<ul>
<li>appelez le <a href="tel:${phoneNumber},,${pin}"><strong>${format.formatFrenchPhoneNumber(phoneNumber)}</strong></a> (numéro non surtaxé) sur votre téléphone fixe ou mobile</li>
Expand All @@ -113,11 +118,15 @@ module.exports.sendConfCreatedEmail = async function(
</div>
<div class="paragraph">
Bonne journée avec ${config.APP_NAME} !
Bonne journée avec <a href="${config.HOSTNAME_WITH_PROTOCOL}">${config.APP_NAME}</a> !
</div>
<hr />
${pollHtml}
<div>
Créez votre propre conférence téléphonique, en toute autonomie, en allant sur
<a href="${config.HOSTNAME_WITH_PROTOCOL}">${config.APP_NAME}</a>
</div>
`

try {
Expand All @@ -139,7 +148,7 @@ module.exports.sendSurveyEmail = async function (toEmail) {
<p></p>
<p>Avez-vous apprécié <b>${config.APP_NAME}</b> ?</p>
<p>Avez-vous eu des difficultés qui vous ont irrité.e ?</p>
<p>Avez-vous eu des difficultés qui vous ont irrité.es ?</p>
<p>Nous aimerions le savoir pour nous améliorer !</p>
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "conferences",
"version": "1.9.0",
"version": "1.10.0",
"description": "Conférences audio et vidéo pour les fonctionnaires de l'Etat",
"main": "index.js",
"directories": {
Expand Down
2 changes: 1 addition & 1 deletion views/partials/footer.ejs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<!-- todo(estellecomment) : import min css and js -->
<script src="/~/@gouvfr/all/dist/js/all.js"></script>
<script src="/gouvfr/js/all.js"></script>

<footer class="rf-footer" id="footer">
<div class="rf-container">
Expand Down
2 changes: 1 addition & 1 deletion views/partials/header.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<% } %>
</title>
<!-- todo(estellecomment) : import min css and js -->
<link rel="stylesheet" href="/~/@gouvfr/all/dist/css/all.css">
<link rel="stylesheet" href="/gouvfr/css/all.css">
<link rel="stylesheet" href="/static/css/custom.css">
<link rel="icon" type="image/png" sizes="16x16" href="/static/images/favicon/favicon-16x16.png">
<link rel="icon" type="image/png" sizes="32x32" href="/static/images/favicon/favicon-32x32.png">
Expand Down
2 changes: 1 addition & 1 deletion views/stats.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</div>
</div>

<script src="/~/chart.js/dist/Chart.min.js"></script>
<script src="/chart.js/Chart.min.js"></script>

<div id="chart-data" style="display: none;">
<%= JSON.stringify(stats) %>
Expand Down

0 comments on commit a8cf5b6

Please sign in to comment.