Commit 62c00661 authored by Marin Jankovski's avatar Marin Jankovski

Allow creation of the jira and redmine services.

parent 9371c6b9
......@@ -17,7 +17,8 @@ class Projects::ServicesController < Projects::ApplicationController
def update
if @service.update_attributes(service_params)
redirect_to edit_project_service_path(@project, @service.to_param)
redirect_to edit_project_service_path(@project, @service.to_param),
notice: 'Successfully updated.'
else
render 'edit'
end
......@@ -41,7 +42,8 @@ class Projects::ServicesController < Projects::ApplicationController
:title, :token, :type, :active, :api_key, :subdomain,
:room, :recipients, :project_url, :webhook,
:user_key, :device, :priority, :sound, :bamboo_url, :username, :password,
:build_key, :server, :teamcity_url, :build_type
:build_key, :server, :teamcity_url, :build_type,
:description, :issues_url, :new_issue_url
)
end
end
......@@ -68,6 +68,9 @@ class Project < ActiveRecord::Base
has_one :bamboo_service, dependent: :destroy
has_one :teamcity_service, dependent: :destroy
has_one :pushover_service, dependent: :destroy
has_one :jira_service, dependent: :destroy
has_one :redmine_service, dependent: :destroy
has_one :forked_project_link, dependent: :destroy, foreign_key: "forked_to_project_id"
has_one :forked_from_project, through: :forked_project_link
# Merge Requests for target project should be removed with it
......@@ -321,7 +324,7 @@ class Project < ActiveRecord::Base
def available_services_names
%w(gitlab_ci campfire hipchat pivotaltracker flowdock assembla
emails_on_push gemnasium slack pushover buildbox bamboo teamcity)
emails_on_push gemnasium slack pushover buildbox bamboo teamcity jira redmine)
end
def gitlab_ci?
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment