北斗单点登录引起的500问题

This commit is contained in:
huang 2016-05-17 11:23:20 +08:00
parent 11bc6b1e6c
commit 0cba32ecd6
1 changed files with 3 additions and 1 deletions

View File

@ -27,8 +27,10 @@ class SsosController < ApplicationController
## 加入组织
@organization = Organization.find(82)
unless @organization.org_members.exists?(user_id: sso.user_id)
member = OrgMember.new(:user_id => sso.user_id)
member = OrgMember.create(:user_id => sso.user_id, :created_at => Time.now)
# member = OrgMember.new(:user_id => sso.user_id)
@organization.org_members << member
OrgMemberRole.create(:org_member_id => member.id, :role_id => 12)
end
## 选择性跳转