From e30ce627fcd524eb616000d73f6a8450c08e1cba Mon Sep 17 00:00:00 2001 From: Alban Peignier Date: Wed, 25 May 2016 15:53:52 +0200 Subject: Fixes header and footer to remove Chouette specific stuff. Refs #912 --- app/assets/images/stif.png | Bin 0 -> 6398 bytes app/models/offer_workbench.rb | 2 +- app/models/referential.rb | 2 +- app/models/user.rb | 2 +- app/views/layouts/application.html.erb | 2 +- app/views/offer_workbenches/_referential.erb | 12 +++++----- app/views/offer_workbenches/show.html.erb | 3 ++- app/views/referentials/_referential.erb | 12 +++++----- app/views/shared/_footer.erb | 22 ------------------ app/views/shared/_header.erb | 6 +++-- config/environment.rb | 2 +- config/environments/development.rb | 6 ++--- db/seeds.rb | 33 ++++++++++++++++++++------- 13 files changed, 51 insertions(+), 53 deletions(-) create mode 100644 app/assets/images/stif.png diff --git a/app/assets/images/stif.png b/app/assets/images/stif.png new file mode 100644 index 000000000..577d4bb72 Binary files /dev/null and b/app/assets/images/stif.png differ diff --git a/app/models/offer_workbench.rb b/app/models/offer_workbench.rb index a1c8f3b9c..65feafdd5 100644 --- a/app/models/offer_workbench.rb +++ b/app/models/offer_workbench.rb @@ -1,7 +1,7 @@ class OfferWorkbench < ActiveRecord::Base belongs_to :organisation - validates :name, presence: true, uniqueness: true + validates :name, presence: true validates :organisation, presence: true has_many :referentials diff --git a/app/models/referential.rb b/app/models/referential.rb index af2cc2182..b41a7a434 100644 --- a/app/models/referential.rb +++ b/app/models/referential.rb @@ -165,7 +165,7 @@ class Referential < ActiveRecord::Base before_destroy :destroy_jobs def destroy_jobs - Ievkit.delete_jobs(slug) + #Ievkit.delete_jobs(slug) true end diff --git a/app/models/user.rb b/app/models/user.rb index 475e7629c..e00b6a35a 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -11,7 +11,7 @@ class User < ActiveRecord::Base # FIXME https://github.com/nbudin/devise_cas_authenticatable/issues/53 # Work around :validatable, when database_authenticatable is diabled. - attr_accessor :password + attr_accessor :password unless authentication_type == :database_authenticatable # Setup accessible (or protected) attributes for your model # attr_accessible :email, :password, :current_password, :password_confirmation, :remember_me, :name, :organisation_attributes diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index 81f3d1e83..78c4f4a5f 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb @@ -1,7 +1,7 @@
-+
<%= referential.human_attribute_name('lines') %>:
<%= referential.human_attribute_name('networks') %>:
-+
<%= referential.human_attribute_name('vehicle_journeys') %>:
diff --git a/app/views/offer_workbenches/show.html.erb b/app/views/offer_workbenches/show.html.erb index 9a47977e3..43335a68f 100644 --- a/app/views/offer_workbenches/show.html.erb +++ b/app/views/offer_workbenches/show.html.erb @@ -1,5 +1,6 @@ -<%= title_tag @offer_workbench.name %> +<%= title_tag "#{@offer_workbench.name} - Tableau de bord" %>
+
<%= referential.human_attribute_name('lines') %>:
<%= referential.human_attribute_name('networks') %>:
-+
<%= referential.human_attribute_name('vehicle_journeys') %>:
diff --git a/app/views/shared/_footer.erb b/app/views/shared/_footer.erb index e8fe2d5e4..77c19d2fd 100644 --- a/app/views/shared/_footer.erb +++ b/app/views/shared/_footer.erb @@ -3,14 +3,6 @@