-
Notifications
You must be signed in to change notification settings - Fork 244
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[admin] Add ability to accept News submissions with feedback
- Loading branch information
1 parent
30e063e
commit 8a5e72e
Showing
13 changed files
with
158 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 10 additions & 2 deletions
12
lib/changelog_web/templates/admin/news_item/_accept_modal.html.eex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
lib/changelog_web/templates/email/submitted_news_accepted.html.eex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<tr> | ||
<td class="content-block" itemprop="handler" itemscope itemtype="http://schema.org/HttpActionHandler"> | ||
<p><%= greeting(@person) %></p> | ||
|
||
<p>Your <%= link("submission", to: @item.url) %> was <strong>accepted</strong>! It is included in Changelog News #<%= @news.slug %>:</p> | ||
|
||
<ul> | ||
<li><%= link("Audio here", to: url(~p"/news/#{@news.slug}")) %></li> | ||
<li><%= link("Email here", to: url(~p"/news/#{@news.slug}/email")) %></li> | ||
</ul> | ||
|
||
<p>In addition, here is a message from the editor:</p> | ||
|
||
<p><blockquote><%= @item.message |> SharedHelpers.md_to_html() |> raw() %></blockquote></p> | ||
|
||
<p>💚, Logbot</p> | ||
</td> | ||
</tr> |
19 changes: 19 additions & 0 deletions
19
lib/changelog_web/templates/email/submitted_news_accepted.text.eex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<%= greeting(@person) %> | ||
|
||
|
||
Your submission was accepted! It is included in Changelog News #<%= @news.slug %>: | ||
|
||
Audio link: url(~p"/news/#{@news.slug}") | ||
Email link: url(~p"/news/#{@news.slug}/email") | ||
|
||
In addition, here is a message from the editor: | ||
|
||
--- | ||
|
||
<%= @item.message %> | ||
|
||
--- | ||
|
||
If there's more to say or our message requested a response, feel free to reply. | ||
|
||
💚, Logbot |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters