mirror of
https://github.com/zhigang1992/tsemple.git
synced 2026-04-30 21:52:18 +08:00
Add admin user confirm column
This commit is contained in:
@@ -14,7 +14,7 @@ class Admin::UsersController < Admin::ApplicationController
|
||||
end
|
||||
|
||||
def update
|
||||
if @user.update_attributes params.require(:user).permit(:name, :username, :email, :bio, :avatar, :remove_avatar)
|
||||
if @user.update_attributes params.require(:user).permit(:name, :username, :email, :confirmed, :bio, :avatar, :remove_avatar)
|
||||
flash[:success] = I18n.t('admin.users.flashes.successfully_updated')
|
||||
redirect_to admin_user_url(@user)
|
||||
else
|
||||
|
||||
@@ -33,6 +33,11 @@
|
||||
.form-group
|
||||
= f.label :email
|
||||
= f.text_field :email, class: 'form-control', tabIndex: 3
|
||||
.form-group
|
||||
.checkbox
|
||||
label
|
||||
= f.check_box :confirmed
|
||||
= t '.confirmed'
|
||||
.form-group
|
||||
= f.label :bio
|
||||
= f.text_area :bio, class: 'form-control', tabIndex: 4
|
||||
|
||||
Reference in New Issue
Block a user