Fixed missing downcase for login of agents and customers.
This commit is contained in:
parent
87e1a92e39
commit
70f5f21558
1 changed files with 56 additions and 56 deletions
|
@ -6,13 +6,13 @@ module Import::OTRS
|
||||||
|
|
||||||
=begin
|
=begin
|
||||||
|
|
||||||
result = request_json( :Subaction => 'List', 1)
|
result = request_json(Subaction: 'List', 1)
|
||||||
|
|
||||||
return
|
return
|
||||||
|
|
||||||
{ some json structure }
|
{ some json structure }
|
||||||
|
|
||||||
result = request_json( :Subaction => 'List' )
|
result = request_json(Subaction: 'List')
|
||||||
|
|
||||||
return
|
return
|
||||||
|
|
||||||
|
@ -257,13 +257,13 @@ module Import::OTRS
|
||||||
return
|
return
|
||||||
|
|
||||||
{
|
{
|
||||||
:Ticket => {
|
Ticket: {
|
||||||
:total => 1234,
|
total: 1234,
|
||||||
:done => 13,
|
done: 13,
|
||||||
},
|
},
|
||||||
:Base => {
|
Base: {
|
||||||
:total => 1234,
|
total: 1234,
|
||||||
:done => 13,
|
done: 13,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -612,7 +612,7 @@ module Import::OTRS
|
||||||
|
|
||||||
# find owner
|
# find owner
|
||||||
if ticket_new[:owner]
|
if ticket_new[:owner]
|
||||||
user = User.lookup(login: ticket_new[:owner])
|
user = User.find_by(login: ticket_new[:owner].downcase)
|
||||||
ticket_new[:owner_id] = if user
|
ticket_new[:owner_id] = if user
|
||||||
user.id
|
user.id
|
||||||
else
|
else
|
||||||
|
@ -623,7 +623,7 @@ module Import::OTRS
|
||||||
|
|
||||||
# find customer
|
# find customer
|
||||||
if ticket_new[:customer]
|
if ticket_new[:customer]
|
||||||
user = User.lookup(login: ticket_new[:customer])
|
user = User.lookup(login: ticket_new[:customer].downcase)
|
||||||
ticket_new[:customer_id] = if user
|
ticket_new[:customer_id] = if user
|
||||||
user.id
|
user.id
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in a new issue