mirror of
https://github.com/openSUSE/osem.git
synced 2026-08-13 19:54:02 +00:00
Add logo to conference page
This commit is contained in:
parent
caa0dec6c4
commit
1d7670d74e
12 changed files with 61 additions and 18 deletions
|
|
@ -7,6 +7,10 @@ html, body,.container,.content {
|
||||||
height: 60px;
|
height: 60px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.well {
|
||||||
|
background-color: white;
|
||||||
|
border: 1px solid #299A0B;
|
||||||
|
}
|
||||||
.container, .content {
|
.container, .content {
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
class Conference < ActiveRecord::Base
|
class Conference < ActiveRecord::Base
|
||||||
attr_accessible :title, :short_title, :social_tag, :contact_email, :timezone, :html_export_path,
|
attr_accessible :title, :short_title, :social_tag, :contact_email, :timezone, :html_export_path,
|
||||||
:start_date, :end_date, :rooms_attributes, :tracks_attributes,
|
:start_date, :end_date, :rooms_attributes, :tracks_attributes,
|
||||||
:event_types_attributes, :registration_start_date, :registration_end_date
|
:event_types_attributes, :registration_start_date, :registration_end_date, :logo
|
||||||
|
|
||||||
has_paper_trail
|
has_paper_trail
|
||||||
|
|
||||||
|
|
@ -21,6 +21,13 @@ class Conference < ActiveRecord::Base
|
||||||
accepts_nested_attributes_for :event_types, :allow_destroy => true
|
accepts_nested_attributes_for :event_types, :allow_destroy => true
|
||||||
accepts_nested_attributes_for :email_settings
|
accepts_nested_attributes_for :email_settings
|
||||||
|
|
||||||
|
has_attached_file :logo,
|
||||||
|
:styles => {:thumb => "100x100>", :large => "300x300>" }
|
||||||
|
|
||||||
|
validates_attachment_content_type :logo,
|
||||||
|
:content_type => [/jpg/, /jpeg/, /png/, /gif/],
|
||||||
|
:size => { :in => 0..500.kilobytes }
|
||||||
|
|
||||||
validates_presence_of :title,
|
validates_presence_of :title,
|
||||||
:short_title,
|
:short_title,
|
||||||
:social_tag
|
:social_tag
|
||||||
|
|
|
||||||
|
|
@ -13,5 +13,8 @@
|
||||||
= f.input :end_date, :as => :string, :input_html => { :id => "conference-end-datepicker", :readonly => "readonly" }
|
= f.input :end_date, :as => :string, :input_html => { :id => "conference-end-datepicker", :readonly => "readonly" }
|
||||||
= f.input :registration_start_date, :as => :string, :input_html => { :id => "conference-reg-start-datepicker", :readonly => "readonly" }
|
= f.input :registration_start_date, :as => :string, :input_html => { :id => "conference-reg-start-datepicker", :readonly => "readonly" }
|
||||||
= f.input :registration_end_date, :as => :string, :input_html => { :id => "conference-reg-end-datepicker", :readonly => "readonly" }
|
= f.input :registration_end_date, :as => :string, :input_html => { :id => "conference-reg-end-datepicker", :readonly => "readonly" }
|
||||||
|
- if !@conference.logo.blank?
|
||||||
|
= image_tag @conference.logo(:thumb)
|
||||||
|
= f.input :logo, :label => "Conference Logo", :hint => "This will be displayed on the front page."
|
||||||
= f.input :html_export_path, :hint => "The path for static HTML exports"
|
= f.input :html_export_path, :hint => "The path for static HTML exports"
|
||||||
= f.action :submit, :as => :button, :button_html => {:class => "btn btn-primary"}
|
= f.action :submit, :as => :button, :button_html => {:class => "btn btn-primary"}
|
||||||
|
|
@ -1,20 +1,28 @@
|
||||||
.container-fluid
|
.container-fluid
|
||||||
%h1.center-text
|
%h1.center-text{:style => "padding-bottom: 30px"}
|
||||||
Upcoming Conferences
|
Upcoming Conferences
|
||||||
- @conferences.each do |conference|
|
- @conferences.each do |conference|
|
||||||
- if conference.cfp_open? || conference.registration_open?
|
- if conference.cfp_open? || conference.registration_open?
|
||||||
.well
|
.well
|
||||||
%h2.center-text
|
.row-fluid
|
||||||
= conference.title
|
.span3.offset3
|
||||||
%h4.center-text
|
= image_tag conference.logo(:original)
|
||||||
= conference.date_range_string
|
.span3
|
||||||
.center-text
|
%h2.center-text
|
||||||
%i
|
= conference.title
|
||||||
%a= link_to conference.venue.name, conference.venue.website
|
%h4.center-text
|
||||||
,
|
= conference.date_range_string
|
||||||
= conference.venue.address
|
.center-text
|
||||||
|
%i
|
||||||
|
%a= link_to conference.venue.name, conference.venue.website
|
||||||
|
,
|
||||||
|
= conference.venue.address
|
||||||
|
.row-fluid
|
||||||
|
.span12
|
||||||
|
.center-text
|
||||||
|
= conference.venue.description
|
||||||
.row-fluid{:style => "padding-top: 30px;"}
|
.row-fluid{:style => "padding-top: 30px;"}
|
||||||
.span4
|
.span3
|
||||||
- if conference.registration_open?
|
- if conference.registration_open?
|
||||||
- if conference.user_registered?(current_user)
|
- if conference.user_registered?(current_user)
|
||||||
= link_to "Modify Registration", register_conference_path(conference.short_title), :class => "btn btn-success btn-large"
|
= link_to "Modify Registration", register_conference_path(conference.short_title), :class => "btn btn-success btn-large"
|
||||||
|
|
@ -23,9 +31,9 @@
|
||||||
= link_to "Register", register_conference_path(conference.short_title), :class => "btn btn-success btn-large"
|
= link_to "Register", register_conference_path(conference.short_title), :class => "btn btn-success btn-large"
|
||||||
- else
|
- else
|
||||||
%b Registration is closed.
|
%b Registration is closed.
|
||||||
.span4.offset4.pull-right
|
.span9
|
||||||
- if conference.cfp_open?
|
- if conference.cfp_open?
|
||||||
- if !current_user.nil? && current_user.person.proposal_count(conference) > 0
|
- if !current_user.nil? && current_user.person.proposal_count(conference) > 0
|
||||||
= link_to "View My Proposals", conference_proposal_index_path(conference.short_title), :class => "btn btn-success btn-large"
|
= link_to "View My Proposals", conference_proposal_index_path(conference.short_title), :class => "btn btn-success btn-large pull-right"
|
||||||
- else
|
- else
|
||||||
= link_to "Submit Proposal", conference_proposal_index_path(conference.short_title), :class => "btn btn-success btn-large"
|
= link_to "Submit Proposal", conference_proposal_index_path(conference.short_title), :class => "btn btn-success btn-large pull-right"
|
||||||
|
|
@ -0,0 +1,8 @@
|
||||||
|
class AddLogoToConferencesTable < ActiveRecord::Migration
|
||||||
|
def change
|
||||||
|
add_column :conferences, :logo_file_name, :string
|
||||||
|
add_column :conferences, :logo_content_type, :string
|
||||||
|
add_column :conferences, :logo_file_size, :integer
|
||||||
|
add_column :conferences, :logo_updated_at, :datetime
|
||||||
|
end
|
||||||
|
end
|
||||||
Binary file not shown.
File diff suppressed because one or more lines are too long
Binary file not shown.
File diff suppressed because one or more lines are too long
Binary file not shown.
Binary file not shown.
|
|
@ -43,8 +43,8 @@ rails.png: rails-a3386665c05a2d82f711a4aaa72d247c.png
|
||||||
rails/index.png: rails-a3386665c05a2d82f711a4aaa72d247c.png
|
rails/index.png: rails-a3386665c05a2d82f711a4aaa72d247c.png
|
||||||
application.js: application-29159c13c2c5ef2fb3368b9d8e2f08a4.js
|
application.js: application-29159c13c2c5ef2fb3368b9d8e2f08a4.js
|
||||||
application/index.js: application-29159c13c2c5ef2fb3368b9d8e2f08a4.js
|
application/index.js: application-29159c13c2c5ef2fb3368b9d8e2f08a4.js
|
||||||
application.css: application-9ab0f7f46e02dcd8c53c1038b1590fb3.css
|
application.css: application-a27f5b2eb07c9d527e71e7faa1f98399.css
|
||||||
application/index.css: application-9ab0f7f46e02dcd8c53c1038b1590fb3.css
|
application/index.css: application-a27f5b2eb07c9d527e71e7faa1f98399.css
|
||||||
loading.gif: loading-b7ff30d20adcf2b850f420d17048930c.gif
|
loading.gif: loading-b7ff30d20adcf2b850f420d17048930c.gif
|
||||||
loading/index.gif: loading-b7ff30d20adcf2b850f420d17048930c.gif
|
loading/index.gif: loading-b7ff30d20adcf2b850f420d17048930c.gif
|
||||||
progressbar.gif: progressbar-bc538af0ba6ff3d792217a96651cd58a.gif
|
progressbar.gif: progressbar-bc538af0ba6ff3d792217a96651cd58a.gif
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue