1
0
mirror of https://github.com/meineerde/redmine.git synced 2026-02-10 20:55:21 +00:00

Add description field to custom fields API (#37617).

Patch by Holger Just and Go MAEDA.


git-svn-id: https://svn.redmine.org/redmine/trunk@21793 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Go MAEDA 2022-09-01 05:25:04 +00:00
parent 6755063664
commit 099a9adcb3
3 changed files with 3 additions and 0 deletions

View File

@ -3,6 +3,7 @@ api.array :custom_fields do
api.custom_field do
api.id field.id
api.name field.name
api.description field.description
api.customized_type field.class.customized_class.name.underscore if field.class.customized_class
api.field_format field.field_format
api.regexp field.regexp

View File

@ -1,6 +1,7 @@
---
custom_fields_001:
name: Database
description: Select one of the databases
regexp: ""
is_for_all: true
is_filter: true

View File

@ -30,6 +30,7 @@ class Redmine::ApiTest::CustomFieldsTest < Redmine::ApiTest::Base
assert_select 'custom_fields' do
assert_select 'custom_field' do
assert_select 'name', :text => 'Database'
assert_select 'description', :text => 'Select one of the databases'
assert_select 'id', :text => '2'
assert_select 'customized_type', :text => 'issue'
assert_select 'possible_values[type=array]' do