Просмотр исходного кода

Merge pull request #1497 from weseek/feat/adjust-swagger-components

Fix/adjust swagger components
Yuki Takei 6 лет назад
Родитель
Сommit
f3a557c81c
2 измененных файлов с 7 добавлено и 12 удалено
  1. 4 8
      src/server/routes/apiv3/customize-setting.js
  2. 3 4
      src/server/routes/apiv3/markdown-setting.js

+ 4 - 8
src/server/routes/apiv3/customize-setting.js

@@ -130,14 +130,10 @@ module.exports = (crowi) => {
    *            content:
    *            content:
    *              application/json:
    *              application/json:
    *                schema:
    *                schema:
-   *                  $ref: '#/components/schemas/CustomizeLayoutTheme'
-   *                  $ref: '#/components/schemas/CustomizeBehavior'
-   *                  $ref: '#/components/schemas/CustomizeFunction'
-   *                  $ref: '#/components/schemas/CustomizeHighlight'
-   *                  $ref: '#/components/schemas/CustomizeTitle'
-   *                  $ref: '#/components/schemas/CustomizeHeader'
-   *                  $ref: '#/components/schemas/CustomizeCss'
-   *                  $ref: '#/components/schemas/CustomizeScript'
+   *                  properties:
+   *                    customizeParams:
+   *                      type: object
+   *                      description: customize params
    */
    */
   router.get('/', loginRequiredStrictly, adminRequired, async(req, res) => {
   router.get('/', loginRequiredStrictly, adminRequired, async(req, res) => {
 
 

+ 3 - 4
src/server/routes/apiv3/markdown-setting.js

@@ -100,10 +100,9 @@ module.exports = (crowi) => {
    *              application/json:
    *              application/json:
    *                schema:
    *                schema:
    *                  properties:
    *                  properties:
-   *                    markdonwParams:
-   *                      $ref: '#/components/schemas/LineBreakParams'
-   *                      $ref: '#/components/schemas/PresentationParams'
-   *                      $ref: '#/components/schemas/XssParams'
+   *                    markdownParams:
+   *                      type: object
+   *                      description: markdown params
    */
    */
   router.get('/', loginRequiredStrictly, adminRequired, async(req, res) => {
   router.get('/', loginRequiredStrictly, adminRequired, async(req, res) => {
     const markdownParams = {
     const markdownParams = {