mirror of
https://gitlink.org.cn/Gitlink/forgeplus.git
synced 2026-07-13 21:44:32 +08:00
增加: 已登录用户对用户名、邮箱、电话进行校验
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
class AccountsController < ApplicationController
|
||||
before_action :require_login, only: [:simple_update]
|
||||
before_action :require_login, only: [:login_check, :simple_update]
|
||||
include ApplicationHelper
|
||||
|
||||
#skip_before_action :check_account, :only => [:logout]
|
||||
@@ -333,6 +333,11 @@ class AccountsController < ApplicationController
|
||||
Register::CheckColumnsForm.new(check_params).validate!
|
||||
render_ok
|
||||
end
|
||||
|
||||
def login_check
|
||||
Register::LoginCheckColumnsForm.new(check_params.merge(user: current_user)).validate!
|
||||
render_ok
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
|
||||
Reference in New Issue
Block a user