fix nccu login
This commit is contained in:
parent
7a523281c3
commit
54b874b2c9
|
@ -11,7 +11,7 @@ class SessionsController < Devise::SessionsController
|
||||||
result = false
|
result = false
|
||||||
ldap_filter = "(uid=#{login_uid})"
|
ldap_filter = "(uid=#{login_uid})"
|
||||||
if /@rulingcom.com$/.match(login_uid).nil?
|
if /@rulingcom.com$/.match(login_uid).nil?
|
||||||
# MiddleSiteConnection.establish
|
MiddleSiteConnection.establish
|
||||||
NccuLdapConnection.establish
|
NccuLdapConnection.establish
|
||||||
|
|
||||||
if ($nccu_ldap_connection.bind rescue false)
|
if ($nccu_ldap_connection.bind rescue false)
|
||||||
|
|
|
@ -15,7 +15,7 @@ module MiddleSiteConnection
|
||||||
}
|
}
|
||||||
|
|
||||||
def self.establish
|
def self.establish
|
||||||
# $mid_site_connection = Mysql2::Client.new(@mid_host)
|
$mid_site_connection = Mysql2::Client.new(@mid_host)
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
|
@ -9,7 +9,7 @@ namespace :mid_site do
|
||||||
admin_role = nil
|
admin_role = nil
|
||||||
sub_role = nil
|
sub_role = nil
|
||||||
test_account_ldap_id ='139716'
|
test_account_ldap_id ='139716'
|
||||||
#MiddleSiteConnection.establish
|
MiddleSiteConnection.establish
|
||||||
|
|
||||||
task :sync => :environment do
|
task :sync => :environment do
|
||||||
info_profile = Info.first(conditions: {:key => 'profile'})
|
info_profile = Info.first(conditions: {:key => 'profile'})
|
||||||
|
|
Reference in New Issue