epaper/app/views/admin/e_paper_criterias/emailer.html.erb

173 lines
4.0 KiB
Plaintext
Raw Normal View History

2019-05-28 15:54:32 +00:00
<% paper = @data["paper"] %>
<% page = @data["page"] %>
2019-09-02 04:34:07 +00:00
<% siteurl = @data["siteurl"] %>
2019-05-28 15:54:32 +00:00
<!DOCTYPE html>
<html>
<head>
<title><%= paper.title %></title>
<style type="text/css">
.epaper-show .epaper-show-title {
border-bottom: 2px solid #ddd;
padding: 0 0 10px;
margin: 10px 0 20px;
color: #881f05;
}
.epaper-show .ep-info {
background: #fff;
border-radius: 3px;
padding: 10px;
margin: 0 0 15px;
}
.epaper-show .ep-info-title {
border-bottom: 1px solid #eee;
padding: 0 0 5px;
margin: 0 0 8px;
font-size: 18px;
}
.epaper-show .ep-info-date {
float: left;
width: 50%;
margin: 0 0 5px;
color: #888;
}
.epaper-show .ep-info-period {
float: right;
width: 50%;
margin: 0 0 5px;
text-align: right;
padding: 0 10px 0 0;
color: #888;
}
.epaper-show .ep-info-description {
clear: both;
padding: 10px 0 0;
overflow: hidden;
border-top: 1px solid #eee;
}
.epaper-show .ep-info-description span {
float: right;
width: calc(100% - 90px);
line-height: 1.5;
}
.epaper-show .ep-content-item {
float: left;
width: calc(50% - 20px);
border: 1px solid #ccc;
vertical-align: top;
min-height: 200px;
padding: 20px;
margin: 10px;
}
.epaper-show .ep-content-title {
color: #881f05;
font-size: 20px;
border-left: 4px solid #881f05;
display: block;
padding: 0 0 0 10px;
margin: 0 0 10px;
}
.epaper-show p.ep-content-text {
color: #666;
font-size: 15px;
}
.epaper-show a.ep-content-more {
background: #881f05;
color: #fff;
padding: 2px 10px;
border-radius: 5px;
font-size: 12px;
}
.ep-topic-show .ep-topic-title {
margin: 10px 0;
color: #881f05;
}
.ep-topic-show .ep-topic-date {
background: #fff;
padding: 10px;
border-radius: 3px;
margin: 0 0 10px;
}
.ep-topic-show .ep-topic-content {
font-size: 15px;
line-height: 2;
}
.epaper-form {
background: #fff;
padding: 20px;
width: 100%;
max-width: 300px;
margin: auto;
border-radius: 5px;
box-shadow: 0 0 30px rgba(0, 0, 0, 0.05);
}
.epaper-form input.input-mail {
display: block;
width: 100%;
margin: 0 0 20px;
padding: 5px 10px;
border: 1px solid #ccc;
border-radius: 5px;
color: #333;
}
.epaper-form .btn-primary {
width: 50%;
float: left;
display: block;
}
.epaper-form .btn-white {
background: none;
width: 50%;
outline: none;
float: right;
color: #888;
}
.epaper-form .btn-white:active {
outline: none;
box-shadow: none;
}
.epaper-form .btn-white:hover {
text-decoration: underline;
}
.epaper-form .ep-form-title {
font-size: 20px;
margin: 0 0 15px;
}
.epaper-form h3.ep-form-title .en {
display: none;
}
.epaper-form form {
overflow: hidden;
}
.school-heading{
padding: 20px;
text-align: center;
border-bottom: 1px solid #c8c8c8;
}
</style>
</head>
<body>
<div class="epaper-show">
<h3 class="epaper-show-title"><%= t('e_paper.intro') %></h3>
<div class="ep-info">
<div class="ep-info-title"><%= t('e_paper.title') %><a class="ep-content-title" href="<%= page + "/" + paper.to_param + "?method=topics" %>" target="_blank"><span><%= paper.title %></span></a></div>
2019-05-28 15:54:32 +00:00
<div class="ep-info-date"><%= t('e_paper.date') %><span><%= paper.created_at.strftime("%Y-%m-%d") %></span></div>
<div class="ep-info-description"><%= t('e_paper.description') %><span><%= paper.description %></span></div>
</div>
<div class="ep-content">
<% paper.epaper_topics.desc(:created_at).each do |topic| %>
<div class="ep-content-item">
<a class="ep-content-title" href="<%= page + "/" + topic.to_param %>" target="_blank"><%= topic.title %></a>
2019-09-02 04:34:07 +00:00
<img src="<%= siteurl + "/" + topic.image.thumb.url %>">
2019-05-28 15:54:32 +00:00
<% t = strip_tags(topic.content) %>
2019-09-02 04:34:07 +00:00
<%= topic.description %>
<a class="ep-content-more" href="<%= page + "/" + topic.to_param %>" target="_blank">more</a>
2019-05-28 15:54:32 +00:00
</div>
<% end %>
</div>
</div>
</body>
</html>