View | Details | Raw Unified | Return to bug 35197
Collapse All | Expand All

(-)a/Koha/AdditionalField.pm (+17 lines)
Lines 42-47 sub effective_authorised_value_category { Link Here
42
    return $category;
42
    return $category;
43
}
43
}
44
44
45
=head3 to_api_mapping
46
47
This method returns the mapping for representing an AdditionalField object
48
on the API.
49
50
=cut
51
52
sub to_api_mapping {
53
    return {
54
        id                        => 'additional_field_id',
55
        tablename                 => 'table_name',
56
        authorised_value_category => 'authorised_value_category_name',
57
        marcfield                 => 'marc_field',
58
        marcfield_mode            => 'marc_field_mode'
59
    };
60
}
61
45
sub _type { 'AdditionalField' }
62
sub _type { 'AdditionalField' }
46
63
47
=head1 AUTHOR
64
=head1 AUTHOR
(-)a/api/v1/swagger/definitions/additional_field.yaml (-10 / +9 lines)
Lines 1-26 Link Here
1
---
1
---
2
type: object
2
type: object
3
properties:
3
properties:
4
  id:
4
  additional_field_id:
5
    type: integer
5
    type: integer
6
    description: internally assigned additional field identifier
6
    description: internally assigned additional field identifier
7
    readOnly: true
7
    readOnly: true
8
  tablename:
8
  table_name:
9
    description: name of the table this additional field corresponds to
9
    description: name of the table this additional field corresponds to
10
    type: string
10
    type: string
11
  name:
11
  name:
12
    description: name of the additional field
12
    description: name of the additional field
13
    type: string
13
    type: string
14
  authorised_value_category:
14
  authorised_value_category_name:
15
    description: authorised value category of the additional field
15
    description: authorised value category of the additional field
16
    type:
16
    type:
17
      - string
17
      - string
18
      - "null"
18
      - "null"
19
  marcfield:
19
  marc_field:
20
    description: marcfield of the additional field
20
    description: marc field of the additional field
21
    type: string
21
    type: string
22
  marcfield_mode:
22
  marc_field_mode:
23
    description: marcfield mode of the additional field
23
    description: marc field mode of the additional field
24
    type: string
24
    type: string
25
    enum:
25
    enum:
26
      - get
26
      - get
Lines 31-35 properties: Link Here
31
31
32
additionalProperties: false
32
additionalProperties: false
33
required:
33
required:
34
  - id
34
  - additional_field_id
35
  - tablename
35
  - table_name
36
- 

Return to bug 35197