From 5e80c8866ac60b958b0be6089cb91d4ae565b60c Mon Sep 17 00:00:00 2001 From: Jason Denney Date: Mon, 2 Sep 2013 12:22:26 -0400 Subject: [PATCH] set username to read only --- app/components/user_role_joins.rb | 2 +- app/components/users.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/components/user_role_joins.rb b/app/components/user_role_joins.rb index 47654c5..760819e 100644 --- a/app/components/user_role_joins.rb +++ b/app/components/user_role_joins.rb @@ -5,7 +5,7 @@ class UserRoleJoins < Netzke::Basepack::Grid c.header = false c.title = "User Roles" c.columns = [ - { :name => :user__username, :text => "Username"}, + { :name => :user__username, :text => "Username", :read_only => true}, { :name => :name, :getter => lambda{ |rec| user = User.find_by_id(rec.user_id) user.nil? ? "" : "#{user.first_name} #{user.last_name}" diff --git a/app/components/users.rb b/app/components/users.rb index c56ad94..0109b4d 100644 --- a/app/components/users.rb +++ b/app/components/users.rb @@ -14,7 +14,7 @@ class Users < Netzke::Basepack::Grid c.model = "User" c.columns = [ - :username, + { :name => :username, :read_only => true }, :first_name, :last_name, :email,