summaryrefslogtreecommitdiff
path: root/app/views/projects/team_members/_form.html.haml
blob: 0eb106ee93fd8ddb0a0da2e5d550c3d188eb08bb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
%h3.page-title
  = "New Team member(s)"

= form_for @user_project_relation, as: :team_member, url: project_team_members_path(@project) do |f|
  -if @user_project_relation.errors.any?
    .alert.alert-error
      %ul
        - @user_project_relation.errors.full_messages.each do |msg|
          %li= msg

  %h6 1. Choose people you want in the team
  .clearfix
    = f.label :user_ids, "People"
    .input
      = users_select_tag(:user_ids, multiple: true)

  %h6 2. Set access level for them
  .clearfix
    = f.label :project_access, "Project Access"
    .input= select_tag :project_access, options_for_select(Project.access_options, @user_project_relation.project_access), class: "project-access-select chosen"

  .actions
    = f.submit 'Add users', class: "btn btn-create"
    = link_to "Cancel", project_team_index_path(@project), class: "btn btn-cancel"