swagger UI中的对象枚举?

时间:2016-09-19 04:27:41

标签: swagger swagger-ui swagger-2.0

我的Swagger规范中有一些其他定义:

"action": {
  "title": "Action",
  "description": "Action to apply to matching requests",
  "type": "object",
  "enum": [ 
    {"delayAction": {"$ref": "#/definitions/delayAction"}}, 
    {"abortAction": {"$ref": "#/definitions/abortAction"}},
    {"traceAction": {"$ref": "#/definitions/traceAction"}}
  ]
}

delayActionabortActiontraceAction都已定义。

但在Swagger UI中,action的模型为空。

enter image description here

如何修改我的Swagger定义,以便Swagger UI可以在模型中显示action的定义?

0 个答案:

没有答案