diff --git a/app/admin/user.rb b/app/admin/user.rb index 464798b..8f89d6b 100644 --- a/app/admin/user.rb +++ b/app/admin/user.rb @@ -52,18 +52,6 @@ end end row :other_organisation - # row I18n.t('admin.user_status'), :user_status_id do |us| - # if !us.user_status.nil? then - # link_to us.user_status.name, [:admin, us.user_status] - # end - # end - # row I18n.t('admin.user_type'), :user_type_id do |ut| - # if !ut.user_type.nil? then - # link_to ut.user_type.name, [:admin, ut.user_type] - # else - # '-' - # end - # end row I18n.t('admin.user_role') do (user.roles.map{|ro| link_to ro.name, [:admin, ro]}).join(', ').html_safe end @@ -88,12 +76,6 @@ :as => :select, :collection => Organisation.order('name').map{|orgp|[orgp.name, orgp.id]} f.input :other_organisation - # f.input :user_status_id, :label => I18n.t('admin.user_status'), - # :as => :select, - # :collection => UserStatus.find(:all, :order => 'name ASC').map{|us|[us.name, us.id]} - # f.input :user_type_id, :label => I18n.t('admin.user_type'), - # :as => :select, - # :collection => UserType.find(:all, :order => 'name ASC').map{|ut|[ut.name, ut.id]} f.input :role_ids, :label => I18n.t('admin.user_role'), :as => :select, :multiple => true, diff --git a/app/models/dmptemplate.rb b/app/models/dmptemplate.rb index 981b585..17dbd12 100644 --- a/app/models/dmptemplate.rb +++ b/app/models/dmptemplate.rb @@ -1,7 +1,7 @@ class Dmptemplate < ActiveRecord::Base include GlobalHelpers - attr_accessible :id, :organisation_id, :description, :published, :title, :user_id, :locale, + attr_accessible :id, :organisation_id, :description, :published, :title, :locale, :is_default, :guidance_group_ids, :as => [:default, :admin] #associations between tables diff --git a/db/migrate/20161115132137_remove_unused_fields_from_dmptemplates.rb b/db/migrate/20161115132137_remove_unused_fields_from_dmptemplates.rb new file mode 100644 index 0000000..77594d4 --- /dev/null +++ b/db/migrate/20161115132137_remove_unused_fields_from_dmptemplates.rb @@ -0,0 +1,5 @@ +class RemoveUnusedFieldsFromDmptemplates < ActiveRecord::Migration + def change + remove_column :dmptemplates, :user_id, :integer + end +end