diff --git a/app/assets/stylesheets/public.less b/app/assets/stylesheets/public.less index ff55e52..a5bf7da 100644 --- a/app/assets/stylesheets/public.less +++ b/app/assets/stylesheets/public.less @@ -8,6 +8,7 @@ @import "public/thikbox"; + img{ max-width:100%; } @@ -131,7 +132,11 @@ body { font-weight: bold; font-size: 16px; } body p { - text-align: justify; } + text-align: justify; + table p{ + text-align:left; + } + } body cite { padding: 10px; display: block; } @@ -356,3 +361,17 @@ body { .actu_accueil img { float: right; margin: 10px; } + + +body #main #contenu .condensed{ +th, td{ +p{ +margin:5px 0; +} + +padding-top:0; +padding-bottom:0; +} + +} + diff --git a/app/models/table_content.rb b/app/models/table_content.rb index 439ea9e..ef1e278 100644 --- a/app/models/table_content.rb +++ b/app/models/table_content.rb @@ -4,7 +4,7 @@ class TableContent < ActiveRecord::Base has_many :table_rows, :include => :cel_tables, :order => :position has_many :cel_tables, :through => :table_rows - STYLES = [["avec bordures",1],["sans bordures",2]] + STYLES = [["avec bordures",1],["avec bordures, condensé",2]] after_create do diff --git a/app/views/portlets/render_public/_tablecontent.html.haml b/app/views/portlets/render_public/_tablecontent.html.haml index bed8375..bf01fc8 100644 --- a/app/views/portlets/render_public/_tablecontent.html.haml +++ b/app/views/portlets/render_public/_tablecontent.html.haml @@ -56,7 +56,7 @@ -else - %table + %table{:class =>("condensed" if input.style == 2)} -table_rows = input.table_rows diff --git a/config/database.yml b/config/database.yml index 8a600f1..abcb0f4 100644 --- a/config/database.yml +++ b/config/database.yml @@ -4,10 +4,13 @@ # Ensure the SQLite 3 gem is defined in your Gemfile # gem 'sqlite3' development: - adapter: sqlite3 - database: db/development.sqlite3 + adapter: mysql2 + encoding: utf8 + database: crossey pool: 5 - timeout: 5000 + username: crossey + password: crossey + host: 127.0.0.1 # Warning: The database defined as "test" will be erased and # re-generated from your development database when you run "rake".