suite
This commit is contained in:
parent
ee3d2bdbf6
commit
3053d1d93d
@ -4,9 +4,62 @@ $vert:#7BAE53;
|
||||
$beige:#F1F0EE;
|
||||
|
||||
@import "qi_css/grid";
|
||||
#couv{
|
||||
height:770px;
|
||||
background:center center no-repeat;
|
||||
background-size:cover;
|
||||
|
||||
}
|
||||
|
||||
#bottom{
|
||||
position:absolute;
|
||||
bottom:0;
|
||||
right:0;
|
||||
left:0;
|
||||
background:$grey;
|
||||
.desc{
|
||||
position:absolute;
|
||||
right:0;
|
||||
bottom:0;
|
||||
left:230px;
|
||||
height:136px;
|
||||
color:white;
|
||||
p{
|
||||
font-size:18px;
|
||||
font-weight:bold;
|
||||
margin-bottom:5px;
|
||||
}
|
||||
}
|
||||
#logo{
|
||||
background:white;
|
||||
width:160px;
|
||||
padding:8px 20px;
|
||||
img{
|
||||
height:120px;
|
||||
display:block;
|
||||
margin:auto;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.page_inner{
|
||||
padding:25px 50px;
|
||||
font-size:14px;
|
||||
h1{
|
||||
|
||||
text-transform:uppercase;
|
||||
color:$vert;
|
||||
margin-top:10px;
|
||||
margin-bottom:0px;
|
||||
padding:0;
|
||||
font-size:25px;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
body{
|
||||
|
||||
-webkit-text-size-adjust: none;
|
||||
font-weight:bold;
|
||||
height:100%;
|
||||
width:102%;
|
||||
@ -32,8 +85,8 @@ html{
|
||||
.page{
|
||||
display: block;
|
||||
clear: both;
|
||||
width:786px;
|
||||
|
||||
width:788px;
|
||||
position:relative;
|
||||
min-height: 295mm;
|
||||
page-break-after: always;
|
||||
|
||||
@ -91,6 +144,7 @@ html{
|
||||
.hr{
|
||||
margin:8px 0;
|
||||
height:20px;
|
||||
margin-bottom:0;
|
||||
background:$grey;
|
||||
}
|
||||
}
|
||||
@ -158,7 +212,7 @@ html{
|
||||
}
|
||||
.render_block{
|
||||
padding:10px 0;
|
||||
|
||||
padding-top:0;
|
||||
}
|
||||
|
||||
|
||||
|
@ -43,14 +43,19 @@ class Public::PlumesController < ApplicationController
|
||||
@plume = Plume.find(params[:id])
|
||||
|
||||
respond_to do |format|
|
||||
format.html
|
||||
format.html do
|
||||
render :layout => false
|
||||
end
|
||||
format.pdf do
|
||||
render pdf: 'file_name',
|
||||
disposition: 'inline', # default 'inline'
|
||||
layout: false,
|
||||
page_size: 'A4',
|
||||
viewport_size: '800x600',
|
||||
#page_size: 'A4',
|
||||
zoom: 1,
|
||||
page_width: 210,
|
||||
page_height:297,
|
||||
viewport_size: '800x600',
|
||||
|
||||
template: "public/plumes/print.html.haml" ,
|
||||
margin: { top: 0, # default 10 (mm)
|
||||
bottom: 0,
|
||||
|
@ -2,6 +2,10 @@
|
||||
|
||||
%td=plume_article.title
|
||||
|
||||
%td
|
||||
=link_to "voir", public_plume_article_path(plume_article), :target => "plume_article_#{plume_article.id}"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
@ -25,6 +25,11 @@
|
||||
|
||||
|
||||
#menu_item_informations
|
||||
%p=link_to "Voir l'article", public_plume_article_path(@plume_article), :target => "plume_article_#{@plume_article.id}"
|
||||
|
||||
%p=link_to "Voir la plume", public_plume_path(@plume_article.plume), :target => "plume_#{@plume_article.plume.id}"
|
||||
%p=link_to "Voir la plume (pdf)", print_public_plume_path(@plume_article.plume, :format => "pdf"), :target => "plume_pdf_#{@plume_article.plume.id}"
|
||||
|
||||
%h4
|
||||
Infos sur l'article
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#plume_event_show
|
||||
%h1
|
||||
=@plume_event.title
|
||||
%em=plume_event_human_date(@plume_event)
|
||||
%em=event_human_date(@plume_event)
|
||||
|
||||
.desc=simple_format @plume_event.description
|
@ -2,7 +2,7 @@
|
||||
|
||||
%td=plume.title
|
||||
%td
|
||||
=link_to "voir", public_plume_path(plume)
|
||||
=link_to "voir", public_plume_path(plume), :target => "plume_#{plume.id}"
|
||||
|
||||
|
||||
|
||||
@ -10,5 +10,5 @@
|
||||
= link_to i(:"trash-o"), [:admin, plume], :confirm => 'Voulez-vous vraiment supprimer cet plume ?', :method => :delete, :remote => true
|
||||
|
||||
= link_to i(:pencil), edit_admin_plume_path(plume), :style => "padding:0px 0px 0px 0px;", :remote => true
|
||||
= link_to i(:eye), edit_admin_plume_path(plume), :style => "padding:0px 0px 0px 0px;"
|
||||
= link_to i(:plus), edit_admin_plume_path(plume), :style => "padding:0px 0px 0px 0px;"
|
||||
|
@ -1,4 +1,3 @@
|
||||
!!!
|
||||
%html
|
||||
%head
|
||||
%meta{:charset => "utf-8"}/
|
||||
@ -16,6 +15,24 @@
|
||||
|
||||
.hr
|
||||
|
||||
#couv{:style => "background-image:url('http://lepicvert.org/#{(@plume.image_file.file.url if @plume.image_file)}');"}
|
||||
|
||||
#bottom
|
||||
#logo
|
||||
=image_tag("http://lepicvert.org/logo.png")
|
||||
.desc
|
||||
%p
|
||||
="N°#{@plume.number} - "
|
||||
=@plume.p_version
|
||||
|
||||
Association pour la protection de la nature
|
||||
%br
|
||||
|
||||
Membre de la FRAPNA Isère
|
||||
%br
|
||||
24 place de la Mairie - 38140 Reaumont
|
||||
%br
|
||||
04 76 91 34 33 - contact@lepicvert.asso.fr - www.lepicvert.org
|
||||
|
||||
.page
|
||||
-i = 0
|
||||
@ -37,6 +54,7 @@
|
||||
-i = 0
|
||||
=raw "</div><div class='page'>"
|
||||
|
||||
.page_inner
|
||||
%h1=plume_article.title
|
||||
|
||||
.render_block
|
||||
@ -50,7 +68,7 @@
|
||||
-if i == 2
|
||||
-i = 0
|
||||
=raw "</div><div class='page'>"
|
||||
.page
|
||||
|
||||
.page_header
|
||||
.right
|
||||
=image_tag "http://lepicvert.org/plume-header.png"
|
||||
@ -59,6 +77,7 @@
|
||||
="N°#{@plume.number}"
|
||||
.left Agenda
|
||||
.clear
|
||||
.page_inner
|
||||
-@plume.plume_events.each do |plume_event|
|
||||
.plume_event
|
||||
%h2=plume_event.title
|
||||
@ -80,6 +99,7 @@
|
||||
-@breve_cat = @plume.plume_cats.where(:title => "Brèves").first
|
||||
-if @breve_cat
|
||||
|
||||
.page_inner
|
||||
-@breve_cat.plume_articles.each do |plume_article|
|
||||
.plume_breve
|
||||
%h2=plume_article.title
|
||||
@ -87,5 +107,4 @@
|
||||
.render_block
|
||||
=render plume_article.block
|
||||
|
||||
%div{:style => "width:100px;height:100px;background:red;position:absolute;top:0;right:0;"}
|
||||
|
Loading…
x
Reference in New Issue
Block a user