{"action":"closed","issue":{"url":"https://api.github.com/repos/swagger-api/swagger-ui/issues/4261","repository_url":"https://api.github.com/repos/swagger-api/swagger-ui","labels_url":"https://api.github.com/repos/swagger-api/swagger-ui/issues/4261/labels{/name}","comments_url":"https://api.github.com/repos/swagger-api/swagger-ui/issues/4261/comments","events_url":"https://api.github.com/repos/swagger-api/swagger-ui/issues/4261/events","html_url":"https://github.com/swagger-api/swagger-ui/issues/4261","id":300535204,"number":4261,"title":"Parameter content type other than application/json not displayed","user":{"login":"jonnyry","id":7916532,"avatar_url":"https://avatars3.githubusercontent.com/u/7916532?v=4","gravatar_id":"","url":"https://api.github.com/users/jonnyry","html_url":"https://github.com/jonnyry","followers_url":"https://api.github.com/users/jonnyry/followers","following_url":"https://api.github.com/users/jonnyry/following{/other_user}","gists_url":"https://api.github.com/users/jonnyry/gists{/gist_id}","starred_url":"https://api.github.com/users/jonnyry/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonnyry/subscriptions","organizations_url":"https://api.github.com/users/jonnyry/orgs","repos_url":"https://api.github.com/users/jonnyry/repos","events_url":"https://api.github.com/users/jonnyry/events{/privacy}","received_events_url":"https://api.github.com/users/jonnyry/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-02-27T08:33:18Z","updated_at":"2018-02-27T16:56:57Z","closed_at":"2018-02-27T16:56:57Z","author_association":"NONE","body":"<!--- Provide a general summary of the issue in the title above -->\r\n\r\nSwagger UI does not display a parameter content type other than application/json when the consumes element is set to something else (see YAML below).\r\n\r\nThis can be recreated by pasting the YAML in the newer Swagger online editor.\r\n\r\n| Q                               | A\r\n| ------------------------------- | -------\r\n| Bug or feature request?         | Bug \r\n| Which Swagger/OpenAPI version?  | 2.0\r\n| Which Swagger-UI version?       | 3.11.0\r\n| How did you install Swagger-UI? | Download from Git, used pre-build dist folder\r\n| Which browser & version?    | Any\r\n| Which OS? | Any\r\n\r\n\r\n### Demonstration API definition\r\n\r\n```yaml\r\nswagger: '2.0'\r\ninfo:\r\n  title: Test\r\n  version: '1.0'\r\nhost: 'server.com'\r\nbasePath: /fhir\r\nschemes:\r\n  - http\r\npaths:\r\n  /Patient/$getrecordsection:\r\n    post:\r\n      tags:\r\n        - Get record section\r\n      summary: Retrieve a care record section\r\n      consumes:\r\n        - application/json+fhir\r\n        - application/xml+fhir\r\n      produces:\r\n        - application/json+fhir\r\n        - application/xml+fhir\r\n      parameters:\r\n        - in: body\r\n          name: body\r\n          description: ''\r\n          required: true\r\n          schema:\r\n            $ref: '#/definitions/GetRecordSection'\r\n      responses:\r\n        '200':\r\n          description: OK\r\n        '400':\r\n          description: Bad request\r\ndefinitions:\r\n  GetRecordSection:\r\n    type: object\r\n    properties:\r\n      resourceType:\r\n        type: string\r\n        default: \"Parameters\"\r\n      parameter:\r\n        type: string\r\n    example:\r\n      resourceType: \"Parameters\"\r\n      parameter: \r\n        - name: \"patientIdentifier\"\r\n          valueIdentifier: \r\n            system: \"http://fhir.provider.net/Id/patient-identifier\"\r\n            value: \"9999999999\"\r\n        - name: \"recordSection\"\r\n          valueCodeableConcept: \r\n            coding:\r\n              - system: \"http://fhir.provider.net/ValueSet/record-section\"\r\n                code: \"ALL\"\r\n    xml:\r\n      name: Parameters\r\n```\r\n\r\n### Expected Behavior\r\nThe parameter content type drop down should display the values listed in the consumes element.\r\n\r\n### Current Behavior\r\nThe parameter content type drop down displays only application/json.\r\n\r\nSee https://stackoverflow.com/questions/48997911/swagger-ui-3-x-setting-custom-content-type-for-body-parameter\r\n"}}
{"actor":{"display_login":"webron"}}