forked from bofh/fetsite
AutoCommit Mit Aug 19 21:03:04 CEST 2015
This commit is contained in:
@@ -53,7 +53,7 @@ m.save
|
|||||||
content_tag("i","", class: "ficon "+name )
|
content_tag("i","", class: "ficon "+name )
|
||||||
end
|
end
|
||||||
def fa_icon_stack(name1, name2)
|
def fa_icon_stack(name1, name2)
|
||||||
content_tag("span", content_tag("i","",class:"fa fa-stack-1x fa-"+name1)+ content_tag("i","",class:"fa fa-stack-1x fa-sm fa-"+name2),class: "fa-stack fa-sm")
|
content_tag("span", content_tag("i","",class:"fa fa-stack-2x fa-"+name1)+ content_tag("i","",class:"fa fa-stack-1x fa-"+name2),class: "fa-stack fa-sm")
|
||||||
end
|
end
|
||||||
def ffi1_list
|
def ffi1_list
|
||||||
y=YAML.load_file("#{::Rails.root.to_s}/config/flatfeticon1.yml")
|
y=YAML.load_file("#{::Rails.root.to_s}/config/flatfeticon1.yml")
|
||||||
@@ -153,4 +153,8 @@ end
|
|||||||
raw(out)
|
raw(out)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def meta_itemprop(itemprop, content)
|
||||||
|
tag("meta", itemprop: itemprop, content: content)
|
||||||
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -6,4 +6,16 @@ module AttachmentsHelper
|
|||||||
render(partial:"attachments/attachment_list", object: p.attachments, locals: {editor: (can?(:edit, p)), parent: p} )+ ((can?(:edit, p))? (render partial:"attachments/form_bulk2", object: a ): "")
|
render(partial:"attachments/attachment_list", object: p.attachments, locals: {editor: (can?(:edit, p)), parent: p} )+ ((can?(:edit, p))? (render partial:"attachments/form_bulk2", object: a ): "")
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def render_attachments_list_for(p)
|
||||||
|
a= Attachment.new
|
||||||
|
a.parent=p
|
||||||
|
render(partial:"attachments/attachment_list", object: p.attachments, locals: {editor: (can?(:edit, p)), parent: p} )
|
||||||
|
end
|
||||||
|
|
||||||
|
def render_new_attachments_for(p, text, options={})
|
||||||
|
a= Attachment.new
|
||||||
|
a.parent=p
|
||||||
|
((can?(:edit, p))? (render partial:"attachments/form_bulk2", object: a ): "")+ link_to(text, new_calentry_path(),options)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -1,12 +1,15 @@
|
|||||||
<div id="neuigkeit_<%= neuigkeit_view.id %>" class="contentbox" itemscope itemtype="http://schema.org/Article">
|
<div id="neuigkeit_<%= neuigkeit_view.id %>" class="contentbox" itemscope itemtype="http://schema.org/Article">
|
||||||
<meta itemprop="about" content="<%= neuigkeit_view.text_first_words %>"/>
|
<meta itemprop="about" content="<%= neuigkeit_view.text_first_words %>"/>
|
||||||
|
<%= meta_itemprop("about", neuigkeit_view.text_first_words) %>
|
||||||
<meta itemprop="sameAs" content="<%= neuigkeit_url(neuigkeit_view,:theme=>nil)%>"/>
|
<meta itemprop="sameAs" content="<%= neuigkeit_url(neuigkeit_view,:theme=>nil)%>"/>
|
||||||
<meta itemprop="url" content="<%= neuigkeit_url(neuigkeit_view,:theme=>nil)%>"/>
|
<meta itemprop="url" content="<%= neuigkeit_url(neuigkeit_view,:theme=>nil)%>"/>
|
||||||
|
|
||||||
|
|
||||||
<div>
|
<div><span class="btn-group">
|
||||||
<%= link_to fa_icon("calendar-o")+"nc" , new_calentry_path(), class: "btn" %>
|
<%= link_to fa_icon("edit"), "#", class: "btn" %>
|
||||||
<%= fa_icon_stack("calendar-o","plus") %>
|
|
||||||
|
<%= link_to fa_icon("plus"), "#", class: "btn" %></span>
|
||||||
|
|
||||||
<div class="dropdown pull-right">
|
<div class="dropdown pull-right">
|
||||||
<a class="dropdown-toggle btn" data-toggle="dropdown" title="publish" href="#"><%= fa_icon("mail-forward")%></a>
|
<a class="dropdown-toggle btn" data-toggle="dropdown" title="publish" href="#"><%= fa_icon("mail-forward")%></a>
|
||||||
<ul class="dropdown-menu">
|
<ul class="dropdown-menu">
|
||||||
@@ -63,9 +66,13 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
<%= render_attachments_for(neuigkeit_view) %>
|
<%= render_attachments_list_for(neuigkeit_view) %>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<%= render_new_attachments_for(neuigkeit_view, fa_icon("plus"), {class: "btn"}) %>
|
||||||
|
|
||||||
|
|
||||||
<%= new_question_for(neuigkeit_view) if can? :new, Survey::Question %>
|
<%= new_question_for(neuigkeit_view) if can? :new, Survey::Question %>
|
||||||
<% @questions.each do |q| %>
|
<% @questions.each do |q| %>
|
||||||
<%= render q if can? :show, q %>
|
<%= render q if can? :show, q %>
|
||||||
|
|||||||
Reference in New Issue
Block a user