Skip to content
This repository has been archived by the owner on Nov 28, 2022. It is now read-only.

Commit

Permalink
Display "all paid members" instead of incorrect count in email confir…
Browse files Browse the repository at this point in the history
…m modal
  • Loading branch information
kevinansfield committed Nov 13, 2019
1 parent 9ff39e5 commit 0e5932c
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/controllers/editor.js
Expand Up @@ -537,7 +537,7 @@ export default Controller.extend({
}
}).enqueue(),

// load supplementel data such as the actions list in the background
// load supplementel data such as the members count in the background
backgroundLoader: task(function* () {
if (this.feature.members) {
let membersResponse = yield this.store.query('member', {limit: 1});
Expand Down
6 changes: 5 additions & 1 deletion app/templates/components/gh-publishmenu.hbs
Expand Up @@ -53,7 +53,11 @@
{{#if showEmailConfirmationModal}}
<GhFullscreenModal
@modal="confirm-email-send"
@model={{hash memberCount=this.memberCount isScheduled=(eq this.saveType "schedule")}}
@model={{hash
memberCount=this.memberCount
isScheduled=(eq this.saveType "schedule")
paidOnly=(eq this.post.visibility "paid")
}}
@confirm={{this.confirmEmailSend}}
@close={{this.closeEmailConfirmationModal}}
@modifier="action wide"
Expand Down
5 changes: 4 additions & 1 deletion app/templates/components/modal-confirm-email-send.hbs
Expand Up @@ -4,7 +4,10 @@
<a class="close" href="" title="Close" {{action "closeModal"}}>{{svg-jar "close"}}<span class="hidden">Close</span></a>

<div class="modal-body">
<p><strong>PLEASE NOTE:</strong> You are about to email this post to <strong>{{pluralize this.model.memberCount "member"}}</strong>.</p>
<p>
<strong>PLEASE NOTE:</strong> You are about to email this post to
<strong>{{if this.model.paidOnly "all paid members" (pluralize this.model.memberCount "member")}}</strong>.
</p>
<ul>
{{#if this.model.isScheduled}}
<li>Email will be sent when the post is published at the scheduled time</li>
Expand Down

0 comments on commit 0e5932c

Please sign in to comment.