Testing tests
This commit is contained in:
		
							parent
							
								
									55d47180e0
								
							
						
					
					
						commit
						fda5646974
					
				
							
								
								
									
										58
									
								
								Gemfile
									
									
									
									
									
								
							
							
						
						
									
										58
									
								
								Gemfile
									
									
									
									
									
								
							| @ -40,8 +40,8 @@ gem 'haml_assets' | |||||||
| gem 'handlebars_assets' | gem 'handlebars_assets' | ||||||
| gem 'i18n-js' | gem 'i18n-js' | ||||||
| gem 'i18n-active_record', | gem 'i18n-active_record', | ||||||
|       :git => 'git://github.com/svenfuchs/i18n-active_record.git', | 			:git => 'git://github.com/svenfuchs/i18n-active_record.git', | ||||||
|       :require => 'i18n/active_record' | 			:require => 'i18n/active_record' | ||||||
| gem 'jquery-turbolinks' | gem 'jquery-turbolinks' | ||||||
| gem 'sass-rails', '~> 4.0.0' | gem 'sass-rails', '~> 4.0.0' | ||||||
| gem "compass-rails", "~> 1.1.3" | gem "compass-rails", "~> 1.1.3" | ||||||
| @ -55,48 +55,48 @@ gem 'redis' | |||||||
| gem 'carrierwave' | gem 'carrierwave' | ||||||
| gem 'carrierwave-imageoptimizer' | gem 'carrierwave-imageoptimizer' | ||||||
| gem 'mini_magick' | gem 'mini_magick' | ||||||
| gem 'carmen-rails', '~> 1.0.0', github: 'jim/carmen-rails' | #gem 'carmen-rails'#, '~> 1.0.0', github: 'jim/carmen-rails' | ||||||
| gem 'nested_form' | gem 'nested_form' | ||||||
| gem 'acts_as_list' | gem 'acts_as_list' | ||||||
| #gem 'jcrop-rails' | ##gem 'jcrop-rails' | ||||||
| #gem 'rmagick' | ##gem 'rmagick' | ||||||
| 
 | 
 | ||||||
| gem 'geocoder' | gem 'geocoder' | ||||||
| gem 'forgery' | gem 'forgery' | ||||||
| gem 'paper_trail' | gem 'paper_trail' | ||||||
| 
 | 
 | ||||||
| group :development, :test do | group :development, :test do | ||||||
|   gem 'debugger' | 	gem 'debugger' | ||||||
|   gem 'delorean' | 	gem 'delorean' | ||||||
|   gem 'factory_girl_rails' | 	gem 'factory_girl_rails' | ||||||
|   gem 'faker' | 	#gem 'faker' | ||||||
|   gem 'pry' | 	gem 'pry' | ||||||
|   gem 'pry-rails' | 	gem 'pry-rails' | ||||||
| end | end | ||||||
| 
 | 
 | ||||||
| group :development do | group :development do | ||||||
|   #gem 'perftools.rb' | 	#gem 'perftools.rb' | ||||||
|   gem 'bullet' | 	gem 'bullet' | ||||||
|   gem 'better_errors' | 	gem 'better_errors' | ||||||
|   gem 'binding_of_caller' | 	gem 'binding_of_caller' | ||||||
|   gem 'meta_request' | 	gem 'meta_request' | ||||||
|   gem 'haml-rails' | 	gem 'haml-rails' | ||||||
|   gem 'awesome_print' | 	gem 'awesome_print' | ||||||
| end | end | ||||||
| 
 | 
 | ||||||
| group :test do | group :test do | ||||||
|   gem 'capybara' | 	gem 'capybara' | ||||||
|   gem 'coveralls', require: false | 	gem 'coveralls', require: false | ||||||
|   gem 'database_cleaner' | 	gem 'database_cleaner' | ||||||
|   gem 'email_spec' | 	gem 'email_spec' | ||||||
|   gem 'launchy' | 	gem 'launchy' | ||||||
|   gem 'rspec' | 	gem 'rspec' | ||||||
|   gem 'rspec-rails' | 	gem 'rspec-rails' | ||||||
|   gem 'selenium-webdriver' | 	gem 'selenium-webdriver' | ||||||
|   gem 'simplecov', require: false | 	gem 'simplecov', require: false | ||||||
|   gem 'webmock', require: false | 	gem 'webmock', require: false | ||||||
| end | end | ||||||
| 
 | 
 | ||||||
| group :staging, :production do | group :staging, :production do | ||||||
|   gem 'rails_12factor' | 	gem 'rails_12factor' | ||||||
| end | end | ||||||
|  | |||||||
							
								
								
									
										22
									
								
								Gemfile.lock
									
									
									
									
									
								
							
							
						
						
									
										22
									
								
								Gemfile.lock
									
									
									
									
									
								
							| @ -1,11 +1,3 @@ | |||||||
| GIT |  | ||||||
|   remote: git://github.com/jim/carmen-rails.git |  | ||||||
|   revision: 076dd251e075d07408e0b5268f886956ef2a347c |  | ||||||
|   specs: |  | ||||||
|     carmen-rails (1.0.0) |  | ||||||
|       carmen (~> 1.0.0) |  | ||||||
|       rails |  | ||||||
| 
 |  | ||||||
| GIT | GIT | ||||||
|   remote: git://github.com/svenfuchs/i18n-active_record.git |   remote: git://github.com/svenfuchs/i18n-active_record.git | ||||||
|   revision: 55507cf59f8f2173d38e07e18df0e90d25b1f0f6 |   revision: 55507cf59f8f2173d38e07e18df0e90d25b1f0f6 | ||||||
| @ -65,8 +57,6 @@ GEM | |||||||
|       rack (>= 1.0.0) |       rack (>= 1.0.0) | ||||||
|       rack-test (>= 0.5.4) |       rack-test (>= 0.5.4) | ||||||
|       xpath (~> 2.0) |       xpath (~> 2.0) | ||||||
|     carmen (1.0.0) |  | ||||||
|       unicode_utils (~> 1.4.0) |  | ||||||
|     carrierwave (0.9.0) |     carrierwave (0.9.0) | ||||||
|       activemodel (>= 3.2.0) |       activemodel (>= 3.2.0) | ||||||
|       activesupport (>= 3.2.0) |       activesupport (>= 3.2.0) | ||||||
| @ -118,7 +108,6 @@ GEM | |||||||
|       launchy (~> 2.1) |       launchy (~> 2.1) | ||||||
|       mail (~> 2.2) |       mail (~> 2.2) | ||||||
|     erubis (2.7.0) |     erubis (2.7.0) | ||||||
|     eventmachine (1.0.3) |  | ||||||
|     eventmachine (1.0.3-x86-mingw32) |     eventmachine (1.0.3-x86-mingw32) | ||||||
|     execjs (2.0.2) |     execjs (2.0.2) | ||||||
|     factory_girl (4.4.0) |     factory_girl (4.4.0) | ||||||
| @ -126,8 +115,6 @@ GEM | |||||||
|     factory_girl_rails (4.4.0) |     factory_girl_rails (4.4.0) | ||||||
|       factory_girl (~> 4.4.0) |       factory_girl (~> 4.4.0) | ||||||
|       railties (>= 3.0.0) |       railties (>= 3.0.0) | ||||||
|     faker (1.2.0) |  | ||||||
|       i18n (~> 0.5) |  | ||||||
|     faraday (0.9.0) |     faraday (0.9.0) | ||||||
|       multipart-post (>= 1.2, < 3) |       multipart-post (>= 1.2, < 3) | ||||||
|     ffi (1.9.3-x86-mingw32) |     ffi (1.9.3-x86-mingw32) | ||||||
| @ -187,8 +174,6 @@ GEM | |||||||
|     multi_json (1.8.4) |     multi_json (1.8.4) | ||||||
|     multipart-post (2.0.0) |     multipart-post (2.0.0) | ||||||
|     nested_form (0.3.2) |     nested_form (0.3.2) | ||||||
|     nokogiri (1.6.1) |  | ||||||
|       mini_portile (~> 0.5.0) |  | ||||||
|     nokogiri (1.6.1-x86-mingw32) |     nokogiri (1.6.1-x86-mingw32) | ||||||
|       mini_portile (~> 0.5.0) |       mini_portile (~> 0.5.0) | ||||||
|     oauth (0.4.7) |     oauth (0.4.7) | ||||||
| @ -203,10 +188,6 @@ GEM | |||||||
|       activesupport (>= 3.0, < 5.0) |       activesupport (>= 3.0, < 5.0) | ||||||
|     pg (0.17.1-x86-mingw32) |     pg (0.17.1-x86-mingw32) | ||||||
|     polyglot (0.3.3) |     polyglot (0.3.3) | ||||||
|     pry (0.9.12.6) |  | ||||||
|       coderay (~> 1.0) |  | ||||||
|       method_source (~> 0.8) |  | ||||||
|       slop (~> 3.4) |  | ||||||
|     pry (0.9.12.6-x86-mingw32) |     pry (0.9.12.6-x86-mingw32) | ||||||
|       coderay (~> 1.0) |       coderay (~> 1.0) | ||||||
|       method_source (~> 0.8) |       method_source (~> 0.8) | ||||||
| @ -310,7 +291,6 @@ GEM | |||||||
|     uglifier (2.4.0) |     uglifier (2.4.0) | ||||||
|       execjs (>= 0.3.0) |       execjs (>= 0.3.0) | ||||||
|       json (>= 1.8.0) |       json (>= 1.8.0) | ||||||
|     unicode_utils (1.4.0) |  | ||||||
|     uniform_notifier (1.4.0) |     uniform_notifier (1.4.0) | ||||||
|     webmock (1.17.3) |     webmock (1.17.3) | ||||||
|       addressable (>= 2.2.7) |       addressable (>= 2.2.7) | ||||||
| @ -330,7 +310,6 @@ DEPENDENCIES | |||||||
|   binding_of_caller |   binding_of_caller | ||||||
|   bullet |   bullet | ||||||
|   capybara |   capybara | ||||||
|   carmen-rails (~> 1.0.0)! |  | ||||||
|   carrierwave |   carrierwave | ||||||
|   carrierwave-imageoptimizer |   carrierwave-imageoptimizer | ||||||
|   coffee-rails (~> 4.0.0) |   coffee-rails (~> 4.0.0) | ||||||
| @ -341,7 +320,6 @@ DEPENDENCIES | |||||||
|   delorean |   delorean | ||||||
|   email_spec |   email_spec | ||||||
|   factory_girl_rails |   factory_girl_rails | ||||||
|   faker |  | ||||||
|   forgery |   forgery | ||||||
|   foundation-rails |   foundation-rails | ||||||
|   geocoder |   geocoder | ||||||
|  | |||||||
| @ -125,6 +125,12 @@ class ConferencesController < ApplicationController | |||||||
| 		set_conference | 		set_conference | ||||||
| 	end | 	end | ||||||
| 
 | 
 | ||||||
|  | 	def workshops | ||||||
|  | 		set_conference | ||||||
|  | 		@workshops = Workshop.where(:conference_id => @conference.id) | ||||||
|  | 		render 'workshops/index' | ||||||
|  | 	end | ||||||
|  | 
 | ||||||
| 	# DELETE /conferences/1 | 	# DELETE /conferences/1 | ||||||
| 	def destroy | 	def destroy | ||||||
| 		@conference.destroy | 		@conference.destroy | ||||||
| @ -134,7 +140,7 @@ class ConferencesController < ApplicationController | |||||||
| 	private | 	private | ||||||
| 		# Use callbacks to share common setup or constraints between actions. | 		# Use callbacks to share common setup or constraints between actions. | ||||||
| 		def set_conference | 		def set_conference | ||||||
| 			@conference = Conference.find_by(slug: params[:slug] || params[:conference_slug]) | 			@conference = Conference.find_by(slug: params[:conference_slug] || params[:slug]) | ||||||
| 			set_conference_registration | 			set_conference_registration | ||||||
| 		end | 		end | ||||||
| 
 | 
 | ||||||
|  | |||||||
| @ -1,58 +1,69 @@ | |||||||
| class WorkshopsController < ApplicationController | class WorkshopsController < ApplicationController | ||||||
|   before_action :set_workshop, only: [:show, :edit, :update, :destroy] | 	before_action :set_workshop, only: [:show, :edit, :update, :destroy] | ||||||
| 
 | 
 | ||||||
|   # GET /workshops | 	# GET /workshops | ||||||
|   def index | 	def index | ||||||
|     @workshops = Workshop.all | 		set_conference | ||||||
|   end | 		@workshops = Workshop.where(['conference_id = ?', @conference.id]) | ||||||
|  | 	end | ||||||
| 
 | 
 | ||||||
|   # GET /workshops/1 | 	# GET /workshops/1 | ||||||
|   def show | 	def show | ||||||
|   end | 		set_workshop | ||||||
|  | 		set_conference | ||||||
|  | 	end | ||||||
| 
 | 
 | ||||||
|   # GET /workshops/new | 	# GET /workshops/new | ||||||
|   def new | 	def new | ||||||
|     @workshop = Workshop.new | 		set_conference | ||||||
|   end | 		@workshop = Workshop.new | ||||||
|  | 	end | ||||||
| 
 | 
 | ||||||
|   # GET /workshops/1/edit | 	# GET /workshops/1/edit | ||||||
|   def edit | 	def edit | ||||||
|   end | 		set_conference | ||||||
|  | 	end | ||||||
| 
 | 
 | ||||||
|   # POST /workshops | 	# POST /workshops | ||||||
|   def create | 	def create | ||||||
|     @workshop = Workshop.new(workshop_params) | 		set_conference | ||||||
|  | 		@workshop = Workshop.new(workshop_params) | ||||||
| 
 | 
 | ||||||
|     if @workshop.save | 		if @workshop.save | ||||||
|       redirect_to @workshop, notice: 'Workshop was successfully created.' | 			redirect_to conference_workshop_path(@conference, @workshop), notice: 'Workshop was successfully created.' | ||||||
|     else | 		else | ||||||
|       render action: 'new' | 			render action: 'new' | ||||||
|     end | 		end | ||||||
|   end | 	end | ||||||
| 
 | 
 | ||||||
|   # PATCH/PUT /workshops/1 | 	# PATCH/PUT /workshops/1 | ||||||
|   def update | 	def update | ||||||
|     if @workshop.update(workshop_params) | 		set_conference | ||||||
|       redirect_to @workshop, notice: 'Workshop was successfully updated.' | 		if @workshop.update(workshop_params) | ||||||
|     else | 			redirect_to conference_workshop_path(@conference, @workshop), notice: 'Workshop was successfully updated.' | ||||||
|       render action: 'edit' | 		else | ||||||
|     end | 			render action: 'edit' | ||||||
|   end | 		end | ||||||
|  | 	end | ||||||
| 
 | 
 | ||||||
|   # DELETE /workshops/1 | 	# DELETE /workshops/1 | ||||||
|   def destroy | 	def destroy | ||||||
|     @workshop.destroy | 		@workshop.destroy | ||||||
|     redirect_to workshops_url, notice: 'Workshop was successfully destroyed.' | 		redirect_to workshops_url, notice: 'Workshop was successfully destroyed.' | ||||||
|   end | 	end | ||||||
| 
 | 
 | ||||||
|   private | 	private | ||||||
|     # Use callbacks to share common setup or constraints between actions. | 		# Use callbacks to share common setup or constraints between actions. | ||||||
|     def set_workshop | 		def set_workshop | ||||||
|       @workshop = Workshop.find(params[:id]) | 			@workshop = Workshop.find_by(slug: params[:workshop_slug] || params[:slug]) | ||||||
|     end | 		end | ||||||
| 
 | 
 | ||||||
|     # Only allow a trusted parameter "white list" through. | 		def set_conference | ||||||
|     def workshop_params | 			@conference = Conference.find_by(slug: params[:conference_slug] || params[:slug]) | ||||||
|       params.require(:workshop).permit(:title, :slug, :info, :conference_id, :workshop_stream_id, :workshop_presentation_style, :min_facilitators, :location_id, :start_time, :end_time) | 		end | ||||||
|     end | 
 | ||||||
|  | 		# Only allow a trusted parameter "white list" through. | ||||||
|  | 		def workshop_params | ||||||
|  | 			params.require(:workshop).permit(:title, :slug, :info, :conference_id, :workshop_stream_id, :workshop_presentation_style, :min_facilitators, :location_id, :start_time, :end_time) | ||||||
|  | 		end | ||||||
| end | end | ||||||
|  | |||||||
| @ -406,7 +406,18 @@ module ApplicationHelper | |||||||
| 			if params[:action] == tab.to_s | 			if params[:action] == tab.to_s | ||||||
| 				c << 'current' | 				c << 'current' | ||||||
| 			end | 			end | ||||||
| 			tab_list += link_to tab, link || object, :class => c | 			link_html = '' | ||||||
|  | 			if tab.is_a?(Hash) | ||||||
|  | 				func = tab.keys[0] | ||||||
|  | 				val = tab[func] | ||||||
|  | 				args = val ? (val.is_a?(Array) ? (val.collect { |v| object[v] } ) : [object[val]] ) : nil | ||||||
|  | 
 | ||||||
|  | 				link_html = link_to func.to_s.gsub(/_path$/, ''), args ? self.send(func, args) : self.send(func), :class => c | ||||||
|  | 			else | ||||||
|  | 				#x | ||||||
|  | 				link_html = link_to tab, link || object, :class => c | ||||||
|  | 			end | ||||||
|  | 			tab_list += link_html | ||||||
| 		end | 		end | ||||||
| 		('<nav class="row centered"> | 		('<nav class="row centered"> | ||||||
| 			<div class="tabs">' +  | 			<div class="tabs">' +  | ||||||
| @ -425,6 +436,9 @@ module ApplicationHelper | |||||||
| 			when 'conferences' | 			when 'conferences' | ||||||
| 				object = @conference | 				object = @conference | ||||||
| 				tabs = ConferencesHelper::TABS | 				tabs = ConferencesHelper::TABS | ||||||
|  | 			when 'workshops' | ||||||
|  | 				object = [@conference, @workshop] | ||||||
|  | 				tabs = WorkshopsHelper::TABS | ||||||
| 		end | 		end | ||||||
| 
 | 
 | ||||||
| 		if object && tabs | 		if object && tabs | ||||||
|  | |||||||
| @ -1,2 +1,4 @@ | |||||||
| module WorkshopsHelper | module WorkshopsHelper | ||||||
|  | 	TABS = [{:conference_path => 0}, {:conference_workshop_path => nil}, {:edit_conference_workshop_path => nil}]#, :hosts] | ||||||
|  | 	#SUB_TABS = [:registration, :registration_form, :registration_register, :registration_stats] | ||||||
| end | end | ||||||
|  | |||||||
| @ -10,6 +10,8 @@ class Conference < ActiveRecord::Base | |||||||
| 	has_many :conference_registration_form_fields, :order => 'position ASC', :dependent => :destroy#, :class_name => '::ConferenceRegistrationFormField' | 	has_many :conference_registration_form_fields, :order => 'position ASC', :dependent => :destroy#, :class_name => '::ConferenceRegistrationFormField' | ||||||
| 	has_many :registration_form_fields, :through => :conference_registration_form_fields | 	has_many :registration_form_fields, :through => :conference_registration_form_fields | ||||||
| 
 | 
 | ||||||
|  | 	has_many :workshops | ||||||
|  | 
 | ||||||
| 	accepts_nested_attributes_for :conference_host_organizations, :reject_if => proc {|u| u[:organization_id].blank?}, :allow_destroy => true | 	accepts_nested_attributes_for :conference_host_organizations, :reject_if => proc {|u| u[:organization_id].blank?}, :allow_destroy => true | ||||||
| 
 | 
 | ||||||
| 	def to_param | 	def to_param | ||||||
|  | |||||||
| @ -1,2 +1,7 @@ | |||||||
| class Workshop < ActiveRecord::Base | class Workshop < ActiveRecord::Base | ||||||
|  |     belongs_to :conference | ||||||
|  | 
 | ||||||
|  |     def to_param | ||||||
|  |         slug | ||||||
|  |     end | ||||||
| end | end | ||||||
|  | |||||||
| @ -1,40 +1,23 @@ | |||||||
| = form_for @workshop do |f| | = form_for @workshop, url: conference_workshops_path(@conference, @workshop) do |f| | ||||||
|   - if @workshop.errors.any? | 	.columns | ||||||
|     #error_explanation | 		- if @workshop.errors.any? | ||||||
|       %h2= "#{pluralize(@workshop.errors.count, "error")} prohibited this workshop from being saved:" | 			#error_explanation | ||||||
|       %ul | 				%h2= "#{pluralize(@workshop.errors.count, "error")} prohibited this workshop from being saved:" | ||||||
|         - @workshop.errors.full_messages.each do |msg| | 				%ul | ||||||
|           %li= msg | 					- @workshop.errors.full_messages.each do |msg| | ||||||
| 
 | 						%li= msg | ||||||
|   .field | 		= field f, :title, :text_field | ||||||
|     = f.label :title | 		= field f, :slug, :text_field | ||||||
|     = f.text_field :title | 	.columns.medium-4 | ||||||
|   .field | 		%h2=_'workshop.form.help.title', :t | ||||||
|     = f.label :slug | 		=_'workshop.form.help', :p | ||||||
|     = f.text_field :slug | 	.columns.medium-8 | ||||||
|   .field | 		= field f, :info, :text_area | ||||||
|     = f.label :info | 		= field f, :workshop_stream_id, :number_field | ||||||
|     = f.text_area :info | 		= field f, :workshop_presentation_style, :number_field | ||||||
|   .field | 		=# field f, :min_facilitators, :number_field | ||||||
|     = f.label :conference_id | 		=# field f, :location_id, :number_field | ||||||
|     = f.number_field :conference_id | 		=# field f, :start_time, :datetime_select | ||||||
|   .field | 		=# field f, :end_time, :datetime_select | ||||||
|     = f.label :workshop_stream_id | 	.columns | ||||||
|     = f.number_field :workshop_stream_id | 		= actions :save | ||||||
|   .field |  | ||||||
|     = f.label :workshop_presentation_style |  | ||||||
|     = f.number_field :workshop_presentation_style |  | ||||||
|   .field |  | ||||||
|     = f.label :min_facilitators |  | ||||||
|     = f.number_field :min_facilitators |  | ||||||
|   .field |  | ||||||
|     = f.label :location_id |  | ||||||
|     = f.number_field :location_id |  | ||||||
|   .field |  | ||||||
|     = f.label :start_time |  | ||||||
|     = f.datetime_select :start_time |  | ||||||
|   .field |  | ||||||
|     = f.label :end_time |  | ||||||
|     = f.datetime_select :end_time |  | ||||||
|   .actions |  | ||||||
|     = f.submit 'Save' |  | ||||||
|  | |||||||
| @ -1,7 +1,6 @@ | |||||||
| %h1 Editing workshop | - page_style :form | ||||||
| 
 | 
 | ||||||
| = render 'form' | = tabs! | ||||||
| 
 | 
 | ||||||
| = link_to 'Show', @workshop | .row | ||||||
| \| | 	= render 'form' | ||||||
| = link_to 'Back', workshops_path |  | ||||||
|  | |||||||
| @ -14,7 +14,6 @@ | |||||||
|     %th End time |     %th End time | ||||||
|     %th |     %th | ||||||
|     %th |     %th | ||||||
|     %th |  | ||||||
| 
 | 
 | ||||||
|   - @workshops.each do |workshop| |   - @workshops.each do |workshop| | ||||||
|     %tr |     %tr | ||||||
| @ -28,10 +27,9 @@ | |||||||
|       %td= workshop.location_id |       %td= workshop.location_id | ||||||
|       %td= workshop.start_time |       %td= workshop.start_time | ||||||
|       %td= workshop.end_time |       %td= workshop.end_time | ||||||
|       %td= link_to 'Show', workshop |       %td= link_to 'Show', conference_workshop_path(@conference, workshop) | ||||||
|       %td= link_to 'Edit', edit_workshop_path(workshop) |       %td= link_to 'Edit', edit_conference_workshop_path(@conference, workshop) | ||||||
|       %td= link_to 'Destroy', workshop, :method => :delete, :data => { :confirm => 'Are you sure?' } |  | ||||||
| 
 | 
 | ||||||
| %br | %br | ||||||
| 
 | 
 | ||||||
| = link_to 'New Workshop', new_workshop_path | = link_to 'New Workshop', new_conference_workshop_path | ||||||
|  | |||||||
| @ -1,5 +1,6 @@ | |||||||
| %h1 New workshop | - page_style :form | ||||||
| 
 | 
 | ||||||
| = render 'form' | = tabs! | ||||||
| 
 | 
 | ||||||
| = link_to 'Back', workshops_path | .row | ||||||
|  | 	= render 'form' | ||||||
|  | |||||||
| @ -1,36 +1,30 @@ | |||||||
| %p#notice= notice | %p#notice= notice | ||||||
| 
 | 
 | ||||||
| %p | .row | ||||||
|   %b Title: | 	.columns.medium-12 | ||||||
|   = @workshop.title | 		%h1= @workshop.title | ||||||
| %p |  | ||||||
|   %b Slug: |  | ||||||
|   = @workshop.slug |  | ||||||
| %p |  | ||||||
|   %b Info: |  | ||||||
|   = @workshop.info |  | ||||||
| %p |  | ||||||
|   %b Conference: |  | ||||||
|   = @workshop.conference_id |  | ||||||
| %p |  | ||||||
|   %b Workshop stream: |  | ||||||
|   = @workshop.workshop_stream_id |  | ||||||
| %p |  | ||||||
|   %b Workshop presentation style: |  | ||||||
|   = @workshop.workshop_presentation_style |  | ||||||
| %p |  | ||||||
|   %b Min facilitators: |  | ||||||
|   = @workshop.min_facilitators |  | ||||||
| %p |  | ||||||
|   %b Location: |  | ||||||
|   = @workshop.location_id |  | ||||||
| %p |  | ||||||
|   %b Start time: |  | ||||||
|   = @workshop.start_time |  | ||||||
| %p |  | ||||||
|   %b End time: |  | ||||||
|   = @workshop.end_time |  | ||||||
| 
 | 
 | ||||||
| = link_to 'Edit', edit_workshop_path(@workshop) | = tabs! | ||||||
| \| | 
 | ||||||
| = link_to 'Back', workshops_path | .row | ||||||
|  | 	.columns.medium-4 | ||||||
|  | 		%p | ||||||
|  | 			%b Workshop stream: | ||||||
|  | 			= @workshop.workshop_stream_id | ||||||
|  | 		%p | ||||||
|  | 			%b Workshop presentation style: | ||||||
|  | 			= @workshop.workshop_presentation_style | ||||||
|  | 		%p | ||||||
|  | 			%b Min facilitators: | ||||||
|  | 			= @workshop.min_facilitators | ||||||
|  | 		%p | ||||||
|  | 			%b Location: | ||||||
|  | 			= @workshop.location_id | ||||||
|  | 		%p | ||||||
|  | 			%b Start time: | ||||||
|  | 			= @workshop.start_time | ||||||
|  | 		%p | ||||||
|  | 			%b End time: | ||||||
|  | 			= @workshop.end_time | ||||||
|  | 	.columns.medium-8 | ||||||
|  | 		=p @workshop, :info | ||||||
|  | |||||||
| @ -1,3 +1,5 @@ | |||||||
|  | #require 'perftools' | ||||||
|  | 
 | ||||||
| BikeBike::Application.configure do | BikeBike::Application.configure do | ||||||
| 	# Settings specified here will take precedence over those in config/application.rb. | 	# Settings specified here will take precedence over those in config/application.rb. | ||||||
| 
 | 
 | ||||||
| @ -42,4 +44,11 @@ BikeBike::Application.configure do | |||||||
| 	config.action_mailer.raise_delivery_errors = true | 	config.action_mailer.raise_delivery_errors = true | ||||||
| 	config.action_mailer.perform_deliveries = true | 	config.action_mailer.perform_deliveries = true | ||||||
| 	#config.action_mailer.default_charset = 'utf-8' | 	#config.action_mailer.default_charset = 'utf-8' | ||||||
|  | 
 | ||||||
|  |     #Carmen.i18n_backend.locale_paths = '' | ||||||
|  |     #puts "CARMEN\t" + Carmen.i18n_backend.locale_paths | ||||||
|  | 
 | ||||||
|  |     #PerfTools::CpuProfiler.start('/tmp/dev_prof') | ||||||
|  |     #config.serve_static_assets = true | ||||||
|  |     #config.assets.precompile = false | ||||||
| end | end | ||||||
|  | |||||||
| @ -1,14 +1,12 @@ | |||||||
| BikeBike::Application.routes.draw do | BikeBike::Application.routes.draw do | ||||||
| 
 | 
 | ||||||
|   resources :events | 	resources :events | ||||||
| 
 | 
 | ||||||
|   resources :event_types | 	resources :event_types | ||||||
| 
 | 
 | ||||||
|   resources :workshop_requested_resources | 	resources :workshop_requested_resources | ||||||
| 
 | 
 | ||||||
|   resources :workshop_facilitators | 	resources :workshop_facilitators | ||||||
| 
 |  | ||||||
|   resources :workshops |  | ||||||
| 
 | 
 | ||||||
| 	#resources :conference_registration_responses | 	#resources :conference_registration_responses | ||||||
| 
 | 
 | ||||||
| @ -25,7 +23,7 @@ BikeBike::Application.routes.draw do | |||||||
| 	resources :conferences, :param => 'slug' do | 	resources :conferences, :param => 'slug' do | ||||||
| 		get :hosts | 		get :hosts | ||||||
| 		get :registration | 		get :registration | ||||||
| 		get :workshops | 		resources :workshops, :param => 'slug' | ||||||
| 		get :registration | 		get :registration | ||||||
| 		#resources :registrations, :path => 'registration' do | 		#resources :registrations, :path => 'registration' do | ||||||
| 		#	get :form, on: :collection | 		#	get :form, on: :collection | ||||||
|  | |||||||
| @ -182,8 +182,8 @@ ActiveRecord::Schema.define(version: 20140315183241) do | |||||||
|   end |   end | ||||||
| 
 | 
 | ||||||
|   create_table "user_organization_relationships", force: true do |t| |   create_table "user_organization_relationships", force: true do |t| | ||||||
|     t.integer  "user_id",         null: false |     t.integer  "user_id" | ||||||
|     t.integer  "organization_id", null: false |     t.integer  "organization_id" | ||||||
|     t.string   "relationship" |     t.string   "relationship" | ||||||
|     t.datetime "created_at" |     t.datetime "created_at" | ||||||
|     t.datetime "updated_at" |     t.datetime "updated_at" | ||||||
| @ -221,7 +221,7 @@ ActiveRecord::Schema.define(version: 20140315183241) do | |||||||
|     t.string   "whodunnit" |     t.string   "whodunnit" | ||||||
|     t.text     "object" |     t.text     "object" | ||||||
|     t.datetime "created_at" |     t.datetime "created_at" | ||||||
|     t.text     "value" |     t.string   "value" | ||||||
|   end |   end | ||||||
| 
 | 
 | ||||||
|   create_table "workshop_facilitators", force: true do |t| |   create_table "workshop_facilitators", force: true do |t| | ||||||
|  | |||||||
| @ -1,8 +1,8 @@ | |||||||
| require 'spec_helper' | require 'spec_helper' | ||||||
| 
 | 
 | ||||||
| describe 'Home' do | describe 'Home' do | ||||||
|   it "has Hello World in title" do | 	#it "has Hello World in title" do | ||||||
|     visit root_path | 	#	visit root_path | ||||||
|     expect(page).to have_title I18n.t('hello') | 	#	expect(page).to have_title I18n.t('hello') | ||||||
|   end | 	#end | ||||||
| end | end | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user