-
Notifications
You must be signed in to change notification settings - Fork 45
DEVDOCS-6253 - Content Refresh - "Orders" (Storefront) #975
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
base: main
Are you sure you want to change the base?
Conversation
Reformatted file with reusable schemas. Added new copy. Added missing fields and parameters. Called out legacy extra fields.
- $ref: "#/components/schemas/responseSuccess" | ||
- properties: | ||
data: | ||
type: array | ||
items: | ||
properties: | ||
orderId: | ||
$ref: '#/components/schemas/orderId' | ||
required: | ||
- orderId |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- $ref: "#/components/schemas/responseSuccess" | |
- properties: | |
data: | |
type: array | |
items: | |
properties: | |
orderId: | |
$ref: '#/components/schemas/orderId' | |
required: | |
- orderId | |
- $ref: "#/components/schemas/responseArray" | |
- properties: | |
data: | |
items: | |
properties: | |
orderId: | |
$ref: '#/components/schemas/orderId' | |
required: | |
- orderId |
Changing the schema to one I'll add in another comment. Also removing redundancies and adjusting alignment on the required list
- $ref: "#/components/schemas/responseSuccess" | ||
- properties: | ||
data: | ||
type: array | ||
items: | ||
type: object | ||
properties: | ||
orderId: | ||
$ref: '#/components/schemas/orderId' | ||
imageUrl: | ||
type: string | ||
minLength: 1 | ||
description: The image URL for a product in the order. | ||
example: "https://mybcstore.com/images/products/12345/main.jpg" | ||
required: | ||
- orderId | ||
- imageUrl |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- $ref: "#/components/schemas/responseSuccess" | |
- properties: | |
data: | |
type: array | |
items: | |
type: object | |
properties: | |
orderId: | |
$ref: '#/components/schemas/orderId' | |
imageUrl: | |
type: string | |
minLength: 1 | |
description: The image URL for a product in the order. | |
example: "https://mybcstore.com/images/products/12345/main.jpg" | |
required: | |
- orderId | |
- imageUrl | |
- $ref: "#/components/schemas/responseArray" | |
- properties: | |
data: | |
items: | |
properties: | |
orderId: | |
$ref: '#/components/schemas/orderId' | |
imageUrl: | |
type: string | |
minLength: 1 | |
description: The image URL for a product in the order. | |
example: "https://mybcstore.com/images/products/12345/main.jpg" | |
required: | |
- orderId | |
- imageUrl |
See note above for rationale
- $ref: "#/components/schemas/responseSuccess" | ||
- properties: | ||
data: | ||
type: array | ||
items: | ||
type: object | ||
properties: | ||
productId: | ||
$ref: '#/components/schemas/productId' | ||
quantity: | ||
$ref: '#/components/schemas/quantity' | ||
variantId: | ||
$ref: '#/components/schemas/variantId' | ||
optionList: | ||
$ref: '#/components/schemas/optionList_SIMPLE' | ||
required: | ||
- productId | ||
- quantity | ||
- variantId |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- $ref: "#/components/schemas/responseSuccess" | |
- properties: | |
data: | |
type: array | |
items: | |
type: object | |
properties: | |
productId: | |
$ref: '#/components/schemas/productId' | |
quantity: | |
$ref: '#/components/schemas/quantity' | |
variantId: | |
$ref: '#/components/schemas/variantId' | |
optionList: | |
$ref: '#/components/schemas/optionList_SIMPLE' | |
required: | |
- productId | |
- quantity | |
- variantId | |
- $ref: "#/components/schemas/responseArray" | |
- properties: | |
data: | |
items: | |
properties: | |
productId: | |
$ref: '#/components/schemas/productId' | |
quantity: | |
$ref: '#/components/schemas/quantity' | |
variantId: | |
$ref: '#/components/schemas/variantId' | |
optionList: | |
$ref: '#/components/schemas/optionList_SIMPLE' | |
required: | |
- productId | |
- quantity | |
- variantId |
See note above for rationale
responseObject: | ||
type: object | ||
properties: | ||
code: | ||
type: integer | ||
description: "HTTP Response Code" | ||
default: '200' | ||
message: | ||
type: string | ||
description: "Response message" | ||
default: 'SUCCESS' | ||
data: | ||
type: object | ||
responseSuccess: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
responseObject: | |
type: object | |
properties: | |
code: | |
type: integer | |
description: "HTTP Response Code" | |
default: '200' | |
message: | |
type: string | |
description: "Response message" | |
default: 'SUCCESS' | |
data: | |
type: object | |
responseSuccess: | |
responseObject: | |
type: object | |
properties: | |
code: | |
type: integer | |
description: "HTTP Response Code" | |
default: '200' | |
message: | |
type: string | |
description: "Response message" | |
default: 'SUCCESS' | |
data: | |
type: object | |
responseArray: | |
type: object | |
properties: | |
code: | |
type: integer | |
description: "HTTP Response Code" | |
default: '200' | |
message: | |
type: string | |
description: "Response message" | |
default: 'SUCCESS' | |
data: | |
type: array | |
items: | |
type: object | |
responseSuccess: |
Adding this schema to support the other three suggestions.
Without these four adjustments, it works fine in Swagger, but our own renderer gets lost in the muck.
Reformatted file with reusable schemas.
Added new copy.
Added missing fields and parameters.
Called out legacy extra fields.
DEVDOCS-6253
What changed?
Release notes draft
Anything else?
ping @bc-terra