2018-11-19 16:26:26 -05:00
|
|
|
- page_title _("Environments")
|
2016-04-29 09:14:38 -04:00
|
|
|
|
2021-11-01 05:13:14 -04:00
|
|
|
- if Feature.enabled?(:new_environments_table)
|
|
|
|
#environments-table{ data: { endpoint: project_environments_path(@project, format: :json),
|
|
|
|
"can-read-environment" => can?(current_user, :read_environment, @project).to_s,
|
|
|
|
"can-create-environment" => can?(current_user, :create_environment, @project).to_s,
|
|
|
|
"new-environment-path" => new_project_environment_path(@project),
|
|
|
|
"help-page-path" => help_page_path("ci/environments/index.md"),
|
|
|
|
"project-path" => @project.full_path,
|
|
|
|
"default-branch-name" => @project.default_branch_or_main } }
|
|
|
|
- else
|
|
|
|
- add_page_specific_style 'page_bundles/environments'
|
|
|
|
#environments-list-view{ data: { environments_data: environments_list_data,
|
|
|
|
"can-read-environment" => can?(current_user, :read_environment, @project).to_s,
|
|
|
|
"can-create-environment" => can?(current_user, :create_environment, @project).to_s,
|
|
|
|
"new-environment-path" => new_project_environment_path(@project),
|
|
|
|
"help-page-path" => help_page_path("ci/environments/index.md"),
|
|
|
|
"project-path" => @project.full_path,
|
|
|
|
"default-branch-name" => @project.default_branch_or_main } }
|