foreman_users 0.0.18.4 → 0.0.19
Sign up to get free protection for your applications and to get access to all the features.
- data/app/models/foreman_users/user.rb +2 -2
- data/lib/foreman_users/version.rb +1 -1
- metadata +1 -1
@@ -4,8 +4,8 @@ require "fileutils"
|
|
4
4
|
attr_accessible :title, :body, :username, :ensure , :gid, :groups, :home , :password, :password_max_age, :password_min_age, :shell, :uid, :groups_attributes
|
5
5
|
|
6
6
|
|
7
|
-
has_many :foreman_users_groups, :
|
8
|
-
accepts_nested_attributes_for :
|
7
|
+
has_many :foreman_users_groups, class_name: "ForemanUsers::Group", :foreign_key => :user_id
|
8
|
+
accepts_nested_attributes_for :foreman_users_groups, reject_if: proc { |attributes| attributes['gid'].blank?| attributes['groupname'].blank? | attributes['ensure'].blank? } , allow_destroy: true
|
9
9
|
|
10
10
|
after_create :create_dir
|
11
11
|
after_update :create_dir
|