apigitlabs / apigit-support

APIGIT is a native Git based collaboration platform for API design, document, mock and share.
https://apigit.com
1 stars 0 forks source link

Cannot use allOf in form view #25

Closed fkfv closed 11 months ago

fkfv commented 12 months ago

Is there an existing issue for this?

Describe the Issue

When trying to use allOf for model composition (https://swagger.io/docs/specification/data-models/inheritance-and-polymorphism/) the form view is not working correctly.

If you try to select allOf in form view it will be converted to anyOf If you try to manually add allOf using code view {"type": "string"} will be added to schema, but it will still display in documentation correctly after closing edit view.

Steps To Reproduce

  1. Open edit mode

  2. Create new schema

  3. Try to select allOf as type

  4. It is changed to anyOf

  5. Same schema, open advanced settings or code view

  6. Enter an allOf keyword, example below

  7. It is converted to a string type

{
  "allOf": [
    {
      "type": "object",
      "properties": {
        "test1": {
          "type": "string"
        }
      }
    },
    {
      "type": "object",
      "properties": {
        "test2": {
          "type": "string"
        }
      }
    }
  ]
}

Screenshots or Videos

No response

Browser

Chrome 116

Additional Context?

No response

apigitlabs commented 12 months ago

thanks @fkfv for pointing out the problem, our QA team missed the issue. the bug was fixed and re-deployed online, please help to check if it works well for you at your convenience.

apigitlabs commented 11 months ago

the issue was fixed and close it