diff --git a/CMakeLists.txt b/CMakeLists.txt index 3f7f5af..0e4ca0d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -46,6 +46,7 @@ userver_target_generate_chaotic(${PROJECT_NAME}-chgen RELATIVE_TO ${CMAKE_CURRENT_SOURCE_DIR} ) +target_link_libraries(${PROJECT_NAME}-chgen userver::postgresql) target_link_libraries(${PROJECT_NAME}_objs PUBLIC ${PROJECT_NAME}-chgen) userver_add_sql_library( diff --git a/docs/api/api.yaml b/docs/api/api.yaml index a29c3c9..4f25cf8 100644 --- a/docs/api/api.yaml +++ b/docs/api/api.yaml @@ -296,44 +296,46 @@ components: body: type: string -# Article: -# required: -# - profile -# - body -# - createdAt -# - description -# - isFavorited -# - favoritesCount -# - slug -# - title -# - updatedAt -# type: object -# properties: -# slug: -# type: string -# title: -# type: string -# description: -# type: string -# body: -# type: string -# tags: -# type: array -# items: -# type: string -# createdAt: -# type: string -# format: date-time -# updatedAt: -# type: string -# format: date-time -# isFavorited: -# type: boolean -# favoritesCount: -# type: integer -# profile: -# $ref: '#/components/schemas/Profile' -# additionalProperties: false + Article: + required: + - profile + - body + - createdAt + - description + - isFavorited + - favoritesCount + - slug + - title + - updatedAt + type: object + properties: + slug: + type: string + title: + type: string + description: + type: string + body: + type: string + tags: + type: array + items: + type: string + createdAt: + type: string + format: date-time + x-usrv-cpp-type: userver::storages::postgres::TimePointTz + updatedAt: + type: string + format: date-time + x-usrv-cpp-type: userver::storages::postgres::TimePointTz + isFavorited: + type: boolean + favoritesCount: + type: integer + profile: + $ref: '#/components/schemas/Profile' + additionalProperties: false ArticleFilterDTO: type: object