mirror of
https://gitlab.com/OpenAlt/OpenAltRO/openalt_ro.git
synced 2026-11-23 23:29:14 +00:00
Updated template and content
This commit is contained in:
parent
142a478a6a
commit
9dd5ca83c5
33 changed files with 415 additions and 222 deletions
|
|
@ -1,22 +1,23 @@
|
|||
<section id="feed_preview">
|
||||
<div class="feed_preview">
|
||||
<% counter = 3 %>
|
||||
<% page.posts.forEach(function(post) { %>
|
||||
<% if (counter != 0) { %>
|
||||
<% isEvent = false %>
|
||||
<% post.tags.data.forEach(function(tag) { %>
|
||||
<% if (tag.name == "Events") { %>
|
||||
<% isEvent = true %>
|
||||
<% } %>
|
||||
<% }); %>
|
||||
|
||||
<div class="feed_preview">
|
||||
<% counter = 3 %>
|
||||
<% page.posts.forEach(function(post) { %>
|
||||
<% if (counter != 0) { %>
|
||||
<% isEvent = false %>
|
||||
<% post.tags.data.forEach(function(tag) { %>
|
||||
<% if (tag.name == "Events") { %>
|
||||
<% isEvent = true %>
|
||||
<% if (isEvent == false) { %>
|
||||
<%- include('./../post_feed',
|
||||
{ post: post,
|
||||
source: "index"
|
||||
}) %>
|
||||
<% counter = counter - 1 %>
|
||||
<% } %>
|
||||
<% }); %>
|
||||
|
||||
<% if (isEvent == false) { %>
|
||||
<%- include('./../post_feed', { post: post }) %>
|
||||
<% counter = counter - 1 %>
|
||||
<% } %>
|
||||
<% } %>
|
||||
<% }); %>
|
||||
</div>
|
||||
|
||||
<% }); %>
|
||||
</div>
|
||||
</section>
|
||||
|
|
@ -1,13 +1,11 @@
|
|||
<section class="event">
|
||||
|
||||
<% counter = false %>
|
||||
<% counter = 2 %>
|
||||
<% page.posts.forEach(function(post) { %>
|
||||
<% post.tags.data.forEach(function(tag) { %>
|
||||
<% if ( (tag.name == "Events") && (counter == false) ) { %>
|
||||
<%- include('./../post_event', { post: post }) %>
|
||||
<% counter = true %>
|
||||
<% if ( (tag.name == "Events") && (counter != 0) ) { %>
|
||||
<%- include('./../post_feed', { post: post, source: "index", event: counter }) %>
|
||||
<% counter = counter - 1 %>
|
||||
<% } %>
|
||||
<% }); %>
|
||||
<% }); %>
|
||||
|
||||
</section>
|
||||
Loading…
Add table
Add a link
Reference in a new issue