From d7a613e2024d0efe8ba29cc72e395213be5daf9c Mon Sep 17 00:00:00 2001 From: Kehitt Date: Thu, 20 Sep 2018 12:38:09 +0300 Subject: [PATCH] moved everything back inline schema --- spec/definitions/Report.yaml | 3 --- spec/paths/shops@{shopID}@reports.yaml | 20 +++++++++++++++++++- 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/spec/definitions/Report.yaml b/spec/definitions/Report.yaml index d525f94..1c4d47a 100644 --- a/spec/definitions/Report.yaml +++ b/spec/definitions/Report.yaml @@ -11,12 +11,10 @@ properties: description: Идентификатор отчета type: integer format: int64 - readOnly: true createdAt: description: Дата и время создания type: string format: date-time - readOnly: true fromTime: description: Дата и время начала периода type: string @@ -35,4 +33,3 @@ properties: type: array items: $ref: '#/definitions/FileMeta' - readOnly: true diff --git a/spec/paths/shops@{shopID}@reports.yaml b/spec/paths/shops@{shopID}@reports.yaml index 0e8d26f..c350adf 100644 --- a/spec/paths/shops@{shopID}@reports.yaml +++ b/spec/paths/shops@{shopID}@reports.yaml @@ -11,7 +11,25 @@ post: description: Параметры генерации отчета required: true schema: - $ref: '#/definitions/Report' + type: object + required: + - reportType + - fromTime + - toTime + properties: + reportType: + description: Тип отчета + type: string + enum: + - paymentRegistry + fromTime: + description: Начало временного отрезка + type: string + format: date-time + toTime: + description: Конец временного отрезка + type: string + format: date-time responses: '201': description: Отчет создан