debian-mirror-gitlab/app/helpers/projects/terraform_helper.rb

12 lines
342 B
Ruby
Raw Normal View History

2021-01-29 00:20:46 +05:30
# frozen_string_literal: true
module Projects::TerraformHelper
2021-02-22 17:27:13 +05:30
def js_terraform_list_data(current_user, project)
2021-01-29 00:20:46 +05:30
{
empty_state_image: image_path('illustrations/empty-state/empty-serverless-lg.svg'),
2021-02-22 17:27:13 +05:30
project_path: project.full_path,
terraform_admin: current_user&.can?(:admin_terraform_state, project)
2021-01-29 00:20:46 +05:30
}
end
end