Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions README.ja.md
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,9 @@ ViewCustomize = {
"name": "Project A",
"roles": [
{"id": 6, "name": "RoleX"}
],
"customFields": [
{"id": 4, "name": "[Project Custom field] Text", "value": "text"},
]
},
"issue": {
Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,9 @@ ViewCustomize = {
"name": "Project A",
"roles": [
{"id": 6, "name": "RoleX"}
],
"customFields": [
{"id": 4, "name": "[Project Custom field] Text", "value": "text"},
]
},
"issue": {
Expand Down
3 changes: 2 additions & 1 deletion lib/view_customize/view_hook.rb
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,8 @@ def create_view_customize_context(view_hook_context)
context["project"] = {
"identifier" => project.identifier,
"name" => project.name,
"roles" => user.roles_for_project(project).map {|role| { "id" => role.id, "name" => role.name }}
"roles" => user.roles_for_project(project).map {|role| { "id" => role.id, "name" => role.name }},
"customFields" => project.custom_field_values.map {|field| { "id" => field.custom_field.id, "name" => field.custom_field.name, "value" => field.value }}
}
end

Expand Down