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

(-)a/api/v1/swagger/definitions/suggestion.json (-3 / +15 lines)
Lines 11-16 Link Here
11
    },
11
    },
12
    "suggested_date": {
12
    "suggested_date": {
13
      "type": ["string", "null"],
13
      "type": ["string", "null"],
14
      "format": "date",
14
      "description": "the suggestion was submitted"
15
      "description": "the suggestion was submitted"
15
    },
16
    },
16
    "managed_by": {
17
    "managed_by": {
Lines 19-24 Link Here
19
    },
20
    },
20
    "managed_date": {
21
    "managed_date": {
21
      "type": ["string", "null"],
22
      "type": ["string", "null"],
23
      "format": "date",
22
      "description": "date the suggestion was updated"
24
      "description": "date the suggestion was updated"
23
    },
25
    },
24
    "accepted_by": {
26
    "accepted_by": {
Lines 27-32 Link Here
27
    },
29
    },
28
    "accepted_date": {
30
    "accepted_date": {
29
      "type": ["string", "null"],
31
      "type": ["string", "null"],
32
      "format": "date",
30
      "description": "date the suggestion was marked as accepted"
33
      "description": "date the suggestion was marked as accepted"
31
    },
34
    },
32
    "rejected_by": {
35
    "rejected_by": {
Lines 35-45 Link Here
35
    },
38
    },
36
    "rejected_date": {
39
    "rejected_date": {
37
      "type": ["string", "null"],
40
      "type": ["string", "null"],
41
      "format": "date",
38
      "description": "date the suggestion was marked as rejected"
42
      "description": "date the suggestion was marked as rejected"
39
    },
43
    },
40
    "status": {
44
    "status": {
41
      "type": "string",
45
      "type": "string",
42
      "description": "suggestion status (ASKED, CHECKED, ACCEPTED, or REJECTED)"
46
      "description": "Suggestion status",
47
      "enum": [
48
        "ASKED",
49
        "CHECKED",
50
        "ACCEPTED",
51
        "REJECTED"
52
      ]
43
    },
53
    },
44
    "note": {
54
    "note": {
45
      "type": ["string", "null"],
55
      "type": ["string", "null"],
Lines 55-60 Link Here
55
    },
65
    },
56
    "copyright_date": {
66
    "copyright_date": {
57
      "type": ["string", "null"],
67
      "type": ["string", "null"],
68
      "format": "date",
58
      "description": "copyright date of the suggested item"
69
      "description": "copyright date of the suggested item"
59
    },
70
    },
60
    "publisher_code": {
71
    "publisher_code": {
Lines 63-68 Link Here
63
    },
74
    },
64
    "date_created": {
75
    "date_created": {
65
      "type": ["string", "null"],
76
      "type": ["string", "null"],
77
      "format": "date",
66
      "description": "date created"
78
      "description": "date created"
67
    },
79
    },
68
    "volume_desc": {
80
    "volume_desc": {
Lines 118-127 Link Here
118
      "description": "suggested currency for the suggested price"
130
      "description": "suggested currency for the suggested price"
119
    },
131
    },
120
    "item_price": {
132
    "item_price": {
121
      "type": ["string", "null"],
133
      "type": ["number", "null"],
122
      "description": "suggested price"
134
      "description": "suggested price"
123
    },
135
    },
124
    "total": {
136
    "total_price": {
125
      "type": ["string", "null"],
137
      "type": ["string", "null"],
126
      "description": "suggested total cost (price*quantity updated for currency)"
138
      "description": "suggested total cost (price*quantity updated for currency)"
127
    }
139
    }
(-)a/api/v1/swagger/paths/suggestions.json (-18 / +17 lines)
Lines 6-45 Link Here
6
      "tags": ["patrons", "suggestions"],
6
      "tags": ["patrons", "suggestions"],
7
      "parameters": [
7
      "parameters": [
8
        {
8
        {
9
          "name": "suggestionid",
9
          "name": "suggestion_id",
10
          "in": "query",
10
          "in": "query",
11
          "type": "integer",
11
          "type": "integer",
12
          "description": "Internal suggestion identifier"
12
          "description": "Internal suggestion identifier"
13
        },
13
        },
14
        {
14
        {
15
          "name": "suggestedby",
15
          "name": "suggested_by",
16
          "in": "query",
16
          "in": "query",
17
          "type": "integer",
17
          "type": "integer",
18
          "description": "patron_id for the person making the suggestion, foreign key linking to the borrowers table"
18
          "description": "patron_id for the person making the suggestion, foreign key linking to the borrowers table"
19
        },
19
        },
20
        {
20
        {
21
          "name": "managedby",
21
          "name": "managed_by",
22
          "in": "query",
22
          "in": "query",
23
          "type": "integer",
23
          "type": "integer",
24
          "description": "patron_id for the librarian managing the suggestion, foreign key linking to the borrowers table"
24
          "description": "patron_id for the librarian managing the suggestion, foreign key linking to the borrowers table"
25
        },
25
        },
26
        {
26
        {
27
          "name": "acceptedby",
27
          "name": "accepted_by",
28
          "in": "query",
28
          "in": "query",
29
          "type": "integer",
29
          "type": "integer",
30
          "description": "patron_id for the librarian who accepted the suggestion, foreign key linking to the borrowers table"
30
          "description": "patron_id for the librarian who accepted the suggestion, foreign key linking to the borrowers table"
31
        },
31
        },
32
        {
32
        {
33
          "name": "rejectedby",
33
          "name": "rejected_by",
34
          "in": "query",
34
          "in": "query",
35
          "type": "integer",
35
          "type": "integer",
36
          "description": "patron_id for the librarian who rejected the suggestion, foreign key linking to the borrowers table"
36
          "description": "patron_id for the librarian who rejected the suggestion, foreign key linking to the borrowers table"
37
        },
37
        },
38
        {
38
        {
39
          "name": "STATUS",
39
          "name": "status",
40
          "in": "query",
40
          "in": "query",
41
          "type": "string",
41
          "type": "string",
42
          "description": "suggestion status (ASKED, CHECKED, ACCEPTED, or REJECTED)"
42
          "description": "Suggestion status",
43
          "enum": [
44
            "ASKED",
45
            "CHECKED",
46
            "ACCEPTED",
47
            "REJECTED"
48
          ]
43
        },
49
        },
44
        {
50
        {
45
          "name": "author",
51
          "name": "author",
Lines 54-72 Link Here
54
          "description": "title of the suggested item"
60
          "description": "title of the suggested item"
55
        },
61
        },
56
        {
62
        {
57
          "name": "publishercode",
63
          "name": "publisher_code",
58
          "in": "query",
64
          "in": "query",
59
          "type": "string",
65
          "type": "string",
60
          "description": "publisher of the suggested item"
66
          "description": "publisher of the suggested item"
61
        },
67
        },
62
        {
68
        {
63
          "name": "date",
69
          "name": "date_created",
64
          "in": "query",
70
          "in": "query",
65
          "type": "string",
71
          "type": "string",
66
          "description": "date created"
72
          "description": "date created"
67
        },
73
        },
68
        {
74
        {
69
          "name": "publicationyear",
75
          "name": "publication_year",
70
          "in": "query",
76
          "in": "query",
71
          "type": "string",
77
          "type": "string",
72
          "description": "year of publication"
78
          "description": "year of publication"
Lines 84-90 Link Here
84
          "description": "collection name for the suggested item"
90
          "description": "collection name for the suggested item"
85
        },
91
        },
86
        {
92
        {
87
          "name": "itemtype",
93
          "name": "item_type",
88
          "in": "query",
94
          "in": "query",
89
          "type": "string",
95
          "type": "string",
90
          "description": "suggested item type"
96
          "description": "suggested item type"
Lines 111-117 Link Here
111
        }
117
        }
112
      },
118
      },
113
      "x-koha-authorization": {
119
      "x-koha-authorization": {
114
        "allow-owner": true,
115
        "permissions": {
120
        "permissions": {
116
          "acquisition": "1"
121
          "acquisition": "1"
117
        }
122
        }
Lines 160-166 Link Here
160
        }
165
        }
161
      },
166
      },
162
      "x-koha-authorization": {
167
      "x-koha-authorization": {
163
        "allow-owner": true,
164
        "permissions": {
168
        "permissions": {
165
          "acquisition": "1"
169
          "acquisition": "1"
166
        }
170
        }
Lines 200-207 Link Here
200
        }
204
        }
201
      },
205
      },
202
      "x-koha-authorization": {
206
      "x-koha-authorization": {
203
        "allow-owner": true,
204
        "allow-guarantor": true,
205
        "permissions": {
207
        "permissions": {
206
          "acquisition": "1"
208
          "acquisition": "1"
207
        }
209
        }
Lines 258-264 Link Here
258
        }
260
        }
259
      },
261
      },
260
      "x-koha-authorization": {
262
      "x-koha-authorization": {
261
        "allow-owner": true,
262
        "permissions": {
263
        "permissions": {
263
          "acquisition": "1"
264
          "acquisition": "1"
264
        }
265
        }
Lines 301-307 Link Here
301
        }
302
        }
302
      },
303
      },
303
      "x-koha-authorization": {
304
      "x-koha-authorization": {
304
        "allow-owner": true,
305
        "permissions": {
305
        "permissions": {
306
          "acquisition": "1"
306
          "acquisition": "1"
307
        }
307
        }
308
- 

Return to bug 17314