Fixed typo.

This commit is contained in:
Thorsten Eckel 2016-01-27 19:26:10 +01:00
parent c1c1930bdc
commit 3d238f7974
4 changed files with 10 additions and 10 deletions

View file

@ -177,7 +177,7 @@ Test:
# GET /api/v1/organizations/history/1 # GET /api/v1/organizations/history/1
def history def history
# permissin check # permission check
if !role?(Z_ROLENAME_ADMIN) && !role?(Z_ROLENAME_AGENT) if !role?(Z_ROLENAME_ADMIN) && !role?(Z_ROLENAME_AGENT)
response_access_deny response_access_deny
return return

View file

@ -124,7 +124,7 @@ class TicketArticlesController < ApplicationController
# GET /ticket_attachment/1 # GET /ticket_attachment/1
def attachment def attachment
# permissin check # permission check
ticket = Ticket.find( params[:ticket_id] ) ticket = Ticket.find( params[:ticket_id] )
if !ticket_permission(ticket) if !ticket_permission(ticket)
render( json: 'No such ticket.', status: :unauthorized ) render( json: 'No such ticket.', status: :unauthorized )
@ -161,7 +161,7 @@ class TicketArticlesController < ApplicationController
# GET /ticket_article_plain/1 # GET /ticket_article_plain/1
def article_plain def article_plain
# permissin check # permission check
article = Ticket::Article.find( params[:id] ) article = Ticket::Article.find( params[:id] )
return if !ticket_permission( article.ticket ) return if !ticket_permission( article.ticket )

View file

@ -7,7 +7,7 @@ class TicketsController < ApplicationController
def show def show
@ticket = Ticket.find( params[:id] ) @ticket = Ticket.find( params[:id] )
# permissin check # permission check
return if !ticket_permission(@ticket) return if !ticket_permission(@ticket)
render json: @ticket render json: @ticket
@ -54,7 +54,7 @@ class TicketsController < ApplicationController
def update def update
ticket = Ticket.find(params[:id]) ticket = Ticket.find(params[:id])
# permissin check # permission check
return if !ticket_permission(ticket) return if !ticket_permission(ticket)
if ticket.update_attributes( Ticket.param_validation( params[:ticket] ) ) if ticket.update_attributes( Ticket.param_validation( params[:ticket] ) )
@ -99,7 +99,7 @@ class TicketsController < ApplicationController
# get ticket data # get ticket data
ticket = Ticket.find( params[:id] ) ticket = Ticket.find( params[:id] )
# permissin check # permission check
return if !ticket_permission( ticket ) return if !ticket_permission( ticket )
# get history of ticket # get history of ticket
@ -171,7 +171,7 @@ class TicketsController < ApplicationController
return return
end end
# permissin check # permission check
return if !ticket_permission(ticket_master) return if !ticket_permission(ticket_master)
# check slave ticket # check slave ticket
@ -184,7 +184,7 @@ class TicketsController < ApplicationController
return return
end end
# permissin check # permission check
return if !ticket_permission( ticket_slave ) return if !ticket_permission( ticket_slave )
# check diffetent ticket ids # check diffetent ticket ids
@ -357,7 +357,7 @@ class TicketsController < ApplicationController
fail 'Need user_id or organization_id as param' fail 'Need user_id or organization_id as param'
end end
# permissin check # permission check
#return if !ticket_permission(ticket) #return if !ticket_permission(ticket)
# lookup open user tickets # lookup open user tickets

View file

@ -387,7 +387,7 @@ class UsersController < ApplicationController
# @response_message 401 Invalid session. # @response_message 401 Invalid session.
def history def history
# permissin check # permission check
if !role?(Z_ROLENAME_ADMIN) && !role?('Agent') if !role?(Z_ROLENAME_ADMIN) && !role?('Agent')
response_access_deny response_access_deny
return return