corrected template views; status message now includes oembed; updated post.rb api to supply oembed and object_url
This commit is contained in:
parent
e6d4ec2dc8
commit
414fb8d454
4 changed files with 37 additions and 5 deletions
|
|
@ -24,7 +24,9 @@ class Post < ActiveRecord::Base
|
||||||
t.add :author
|
t.add :author
|
||||||
t.add :post_type
|
t.add :post_type
|
||||||
t.add :image_url
|
t.add :image_url
|
||||||
|
t.add :object_url
|
||||||
t.add :root
|
t.add :root
|
||||||
|
t.add :o_embed_cache
|
||||||
end
|
end
|
||||||
|
|
||||||
xml_attr :provider_display_name
|
xml_attr :provider_display_name
|
||||||
|
|
|
||||||
|
|
@ -1 +1,3 @@
|
||||||
<img src="<%= image_url %>" />
|
<a href="<%= object_url %>" class="stream-photo-link">
|
||||||
|
<img src="<%= image_url %>" data-small-photo="<%= image_url %>" data-full-photo="<%= image_url %>" class="stream-photo" />
|
||||||
|
</a>
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,28 @@
|
||||||
|
<div class="reshare">
|
||||||
|
|
||||||
|
<a href="/people/<%= root.author.id %>">
|
||||||
|
<img src="<%= root.author.avatar.small %>" class="avatar" data-person-id="<%= root.author.id %>"/>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<div class="content">
|
||||||
|
<div class="post_initial_info">
|
||||||
|
<span class="from">
|
||||||
|
<a href="/people/<%= root.author.id %>">
|
||||||
|
<%= root.author.name %>
|
||||||
|
</a>
|
||||||
|
</span>
|
||||||
|
<span class="details">
|
||||||
|
-
|
||||||
|
<a href="/posts/<%= root.id %>">
|
||||||
|
<time class="timeago" datetime="<%= root.created_at %>"/>
|
||||||
|
</a>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- duplicate from statusmessage partial -->
|
||||||
<p>
|
<p>
|
||||||
<h2>this is a reshare</h2>
|
|
||||||
<%= root.text %>
|
<%= root.text %>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,7 @@
|
||||||
<p>
|
<p>
|
||||||
<%= text %>
|
<%= text %>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
<% if(o_embed_cache) { %>
|
||||||
|
<%= o_embed_cache.posts.data.html %>
|
||||||
|
<% } %>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue