2013-08-21 19:16:42 +00:00
|
|
|
Zammad::Application.routes.draw do
|
|
|
|
api_path = Rails.configuration.api_path
|
2012-05-18 13:54:48 +00:00
|
|
|
|
2013-08-21 19:16:42 +00:00
|
|
|
# tickets
|
2017-11-23 08:09:44 +00:00
|
|
|
match api_path + '/tickets/search', to: 'tickets#search', via: %i[get post]
|
2015-09-17 01:04:16 +00:00
|
|
|
match api_path + '/tickets/selector', to: 'tickets#selector', via: :post
|
2016-06-06 15:26:37 +00:00
|
|
|
match api_path + '/tickets', to: 'tickets#index', via: :get
|
2015-04-27 13:42:53 +00:00
|
|
|
match api_path + '/tickets/:id', to: 'tickets#show', via: :get
|
|
|
|
match api_path + '/tickets', to: 'tickets#create', via: :post
|
|
|
|
match api_path + '/tickets/:id', to: 'tickets#update', via: :put
|
2016-06-06 15:26:37 +00:00
|
|
|
match api_path + '/tickets/:id', to: 'tickets#destroy', via: :delete
|
2015-04-27 13:42:53 +00:00
|
|
|
match api_path + '/ticket_create', to: 'tickets#ticket_create', via: :get
|
2015-11-17 14:04:36 +00:00
|
|
|
match api_path + '/ticket_split', to: 'tickets#ticket_split', via: :get
|
2015-04-27 13:42:53 +00:00
|
|
|
match api_path + '/ticket_history/:id', to: 'tickets#ticket_history', via: :get
|
|
|
|
match api_path + '/ticket_customer', to: 'tickets#ticket_customer', via: :get
|
|
|
|
match api_path + '/ticket_related/:ticket_id', to: 'tickets#ticket_related', via: :get
|
2019-06-04 03:40:48 +00:00
|
|
|
match api_path + '/ticket_recent', to: 'tickets#ticket_recent', via: :get
|
2020-08-31 07:51:56 +00:00
|
|
|
match api_path + '/ticket_merge/:slave_ticket_id/:master_ticket_number', to: 'tickets#ticket_merge', via: :put
|
2015-04-27 13:42:53 +00:00
|
|
|
match api_path + '/ticket_stats', to: 'tickets#stats', via: :get
|
2012-05-18 13:54:48 +00:00
|
|
|
|
2013-08-21 19:16:42 +00:00
|
|
|
# ticket overviews
|
2015-04-27 13:42:53 +00:00
|
|
|
match api_path + '/ticket_overviews', to: 'ticket_overviews#show', via: :get
|
2012-07-04 21:36:39 +00:00
|
|
|
|
2013-08-21 19:16:42 +00:00
|
|
|
# ticket priority
|
2015-04-27 13:42:53 +00:00
|
|
|
match api_path + '/ticket_priorities', to: 'ticket_priorities#index', via: :get
|
|
|
|
match api_path + '/ticket_priorities/:id', to: 'ticket_priorities#show', via: :get
|
|
|
|
match api_path + '/ticket_priorities', to: 'ticket_priorities#create', via: :post
|
|
|
|
match api_path + '/ticket_priorities/:id', to: 'ticket_priorities#update', via: :put
|
2016-06-06 06:34:15 +00:00
|
|
|
match api_path + '/ticket_priorities/:id', to: 'ticket_priorities#destroy', via: :delete
|
2012-09-20 12:08:02 +00:00
|
|
|
|
2013-08-21 19:16:42 +00:00
|
|
|
# ticket state
|
2015-04-27 13:42:53 +00:00
|
|
|
match api_path + '/ticket_states', to: 'ticket_states#index', via: :get
|
|
|
|
match api_path + '/ticket_states/:id', to: 'ticket_states#show', via: :get
|
|
|
|
match api_path + '/ticket_states', to: 'ticket_states#create', via: :post
|
|
|
|
match api_path + '/ticket_states/:id', to: 'ticket_states#update', via: :put
|
2016-06-06 06:34:15 +00:00
|
|
|
match api_path + '/ticket_states/:id', to: 'ticket_states#destroy', via: :delete
|
2012-09-20 12:08:02 +00:00
|
|
|
|
2013-08-21 19:16:42 +00:00
|
|
|
# ticket articles
|
2016-06-21 20:59:03 +00:00
|
|
|
match api_path + '/ticket_articles', to: 'ticket_articles#index', via: :get
|
|
|
|
match api_path + '/ticket_articles/:id', to: 'ticket_articles#show', via: :get
|
|
|
|
match api_path + '/ticket_articles/by_ticket/:id', to: 'ticket_articles#index_by_ticket', via: :get
|
|
|
|
match api_path + '/ticket_articles', to: 'ticket_articles#create', via: :post
|
|
|
|
match api_path + '/ticket_articles/:id', to: 'ticket_articles#update', via: :put
|
2016-08-24 11:42:22 +00:00
|
|
|
match api_path + '/ticket_articles/:id', to: 'ticket_articles#destroy', via: :delete
|
2016-06-21 20:59:03 +00:00
|
|
|
match api_path + '/ticket_attachment/:ticket_id/:article_id/:id', to: 'ticket_articles#attachment', via: :get
|
2017-12-05 15:12:52 +00:00
|
|
|
match api_path + '/ticket_attachment_upload_clone_by_article/:article_id', to: 'ticket_articles#ticket_attachment_upload_clone_by_article', via: :post
|
2016-06-21 20:59:03 +00:00
|
|
|
match api_path + '/ticket_article_plain/:id', to: 'ticket_articles#article_plain', via: :get
|
2020-06-02 11:01:16 +00:00
|
|
|
match api_path + '/ticket_articles/:id/retry_security_process', to: 'ticket_articles#retry_security_process', via: :post
|
2015-04-27 14:15:29 +00:00
|
|
|
end
|