Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lost functionality over weekend (worked on Friday) oneOf names not working and lost drop examples #2017

Closed
cleverly87 opened this issue May 23, 2022 · 5 comments · Fixed by #2020
Assignees
Labels

Comments

@cleverly87
Copy link

cleverly87 commented May 23, 2022

Describe the bug
oneOf functionality not displaying the tag names of the correct schema that it references to.
Also the drop down JSON examples that had been hard coded are no long available in the third column.

Expected behavior
A clear and concise description of what you expected to happen.

Minimal reproducible OpenAPI snippet(if possible)
I will copy a trail of the links as the API doc is huge.

PATH
"/localSolutions/GB/identitysearch": {
"post": {
"tags": [
"GB Consumers and AML"
],
"summary": "Submits a GB Consumer or AML Search",
"description": "Submits a GB Consumer or AML depnding on the Product provided. Validates criteria for each individual search before submitting, and may return a list of error strings instead." ,
"parameters": [
{
"$ref": "#/components/parameters/authToken"
}
],
"requestBody": {
"$ref": "#/components/requestBodies/Identity"
},

"requestBodies": {
"Identity": {
"description": "Select the products tab for the request body for each of the products AML and Consumer",
"content": {
"application/json": {
"schema": {
"allOf": [
{
"description": "Identity Search",
"title": "Identity"
},
{
"$ref": "#/components/schemas/Connect.GBConsumer"
}
]
}

}

}
}
},

"Connect.GBConsumer": {
"type": "object",
"description": "Select product type for object parameters and example body.\n\n Options for an AML Search or Consumer Search",
"oneOf": [
{
"$ref" : "#/components/schemas/AMLSearch"
},
{
"$ref": "#/components/schemas/consumerSearch"
}
]
},

  "AMLSearch": {
    "description":	"Search parameters for AML product",
    "properties":	{   
      "UniqueId":	{
        "type":	"string",
        "nullable":	true
      },
      "common": {
        "description": "Person search criteria",	
        "allOf":	[
        {
          "$ref":	"#/components/schemas/Connect.Identity.CommonSearchCriteria"
        }                      
      ]  
    }, 
      "consumer": {
        "description": "Second person search option",
        "$ref": "#/components/schemas/Connect.Identity.ConsumerSearchCriteria"
    },      
      "iDAml":	{
        "description":	"Reference to bank account detail search",
        "allOf":	[
          {
          "$ref": "#/components/schemas/Connect.Identity.AmlSearchCriteria"
        }
        ]            
    },
      "products": {
          "type": "string",
          "description": "Enter `AML` for this product search",
          "example": "AML"
      }
    },        
    "example": {
      "common": {
        "person": {
            "currentName": {
                "title": "",
                "forename": "John",
                "otherNames": "",
                "surname": "Murphy",
                "suffix": ""
            },
            "dateOfBirth": "1974-07-07",
            "gender": "",
            "addresses": {
                "current": {
                    "buildingNo": "",
                    "buildingName": "Stadium Plaza",
                    "street": "Wood Street",
                    "city": "Cardiff",
                    "postCode": "CF10 1LA"
                }
            }
        },
        "reference": ""
    },
      "idAml": {
        "landlineNumber": "",
        "exDirectory": false,
        "sortCode": "",
        "bankAccountNumber": ""
  },
  "products": [
      "Aml"
  ]
    }
  },

Screenshots
The oneOf Tag should look like this
image

But now looks like this:
image

The JSON examples should have this drop down:
image

Now they have completely gone
image

Additional context
I notice there was an update to the oneOf function on friday by one of the devs - please bare in mind im not fully coding experienced so be gentle and try to keep the sarcasm to a minimum.

@anastasiia-developer This something to do with your update Friday?

@cleverly87 cleverly87 changed the title Lost functionality over weekend (worked on Friday) oneOf names not working and lost drop examples Lost functionality over weekend (worked on Friday) oneOf names not working and lost drop examples @anastasiia-developer May 23, 2022
@RomanHotsiy
Copy link
Member

cc @AlexVarchuk

@RomanHotsiy
Copy link
Member

We're actively working on a fix right now. Thanks for reporting.

@anastasiia-developer anastasiia-developer self-assigned this May 23, 2022
@AlexVarchuk AlexVarchuk self-assigned this May 23, 2022
@anastasiia-developer anastasiia-developer removed their assignment May 23, 2022
@AlexVarchuk AlexVarchuk added the p0 label May 23, 2022
@AlexVarchuk AlexVarchuk changed the title Lost functionality over weekend (worked on Friday) oneOf names not working and lost drop examples @anastasiia-developer Lost functionality over weekend (worked on Friday) oneOf names not working and lost drop examples May 23, 2022
@AlexVarchuk
Copy link
Collaborator

related to #1939

@cleverly87
Copy link
Author

Just an update to myside for you to know because I don't know if you have done anything:

I have removed the 'GB consumer' component and referenced the 'oneOf' directly in the request body.

Not sure if this what caused the changed (even thought it worked on Friday) but perhaps overwriting rules in the stack?) here's how it looks now:
image

and the example piece:
image

As it should do, and it is now discriminating the JSON examples as per selection.

@AlexVarchuk
Copy link
Collaborator

@cleverly87 Hi. We are going to make release it next week.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants